/* ===== VARIABLES ===== */
:root {
  --primary: #6366f1;
  --primary-dark: #4f46e5;
  --secondary: #10b981;
  --accent: #f59e0b;
  --dark: #1f2937;
  --light: #f9fafb;
  --gray: #9ca3af;
  --gradient-primary: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  --gradient-secondary: linear-gradient(135deg, #10b981 0%, #3b82f6 100%);
  --gradient-accent: linear-gradient(135deg, #f59e0b 0%, #ef4444 100%);
  --shadow-sm: 0 4px 6px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 10px 15px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 20px 25px rgba(0, 0, 0, 0.15);
  --shadow-xl: 0 25px 50px rgba(0, 0, 0, 0.25);
  --radius: 12px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
 
/* ===== BASE STYLES ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
 
body {
  font-family: 'Inter', 'Segoe UI', sans-serif;
  color: var(--dark);
  background: var(--light);
  line-height: 1.6;
  overflow-x: hidden;
  background-image: 
    radial-gradient(circle at 15% 50%, rgba(99, 102, 241, 0.05) 0%, transparent 25%),
    radial-gradient(circle at 85% 30%, rgba(16, 185, 129, 0.05) 0%, transparent 25%);
}
 
/* ===== ANIMATIONS ===== */
@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}
 
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}
 
@keyframes slideIn {
  from { 
    opacity: 0;
    transform: translateY(30px);
  }
  to { 
    opacity: 1;
    transform: translateY(0);
  }
}
 
@keyframes glow {
  0%, 100% { box-shadow: 0 0 20px rgba(99, 102, 241, 0.3); }
  50% { box-shadow: 0 0 30px rgba(99, 102, 241, 0.6); }
}
 
@keyframes gradientShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}
 
@keyframes pulse-glow {
  0% {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
  }
  50% {
    box-shadow: 0 15px 35px rgba(102, 126, 234, 0.2);
  }
  100% {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
  }
}

@keyframes ripple-animation {
  0% {
    transform: scale(0);
    opacity: 0.5;
  }
  100% {
    transform: scale(2.5);
    opacity: 0;
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translate3d(0, 40px, 0);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

/* Klasy dla animacji (zamiennik Animate.css) */
.animate__animated {
  animation-duration: 1s;
  animation-fill-mode: both;
}

.animate__fadeInUp {
  animation-name: fadeInUp;
}

/* ===== LAYOUT COMPONENTS ===== */
 
/* Navigation */
.navbar {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-sm);
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}
 
.navbar-brand {
  font-weight: 800;
  font-size: 1.8rem;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  position: relative;
}
 
.navbar-brand i {
  padding-right: 10px;
}
 
.navbar-brand::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 30px;
  height: 3px;
  background: var(--gradient-primary);
  border-radius: 2px;
  transition: var(--transition);
}
 
.navbar-brand:hover::after {
  width: 100%;
}
 
.navbar-nav .nav-link {
  font-weight: 600;
  margin: 0 0.3rem;
  padding: 0.5rem 1rem;
  border-radius: 50px;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}
 
.navbar-nav .nav-link::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: var(--gradient-primary);
  transition: var(--transition);
  z-index: -1;
  border-radius: 50px;
}
 
.navbar-nav .nav-link:hover::before {
  left: 0;
}
 
.navbar-nav .nav-link:hover {
  color: white !important;
  transform: translateY(-2px);
}
 
.navbar-nav .nav-link.active {
  background: var(--gradient-primary);
  color: white !important;
  box-shadow: var(--shadow-md);
}
 
/* Hero Section */
.hero {
  min-height: 60vh;
  display: flex;
  align-items: center;
  background: var(--gradient-primary);
  color: white;
  position: relative;
  overflow: hidden;
  margin-bottom: 4rem;
  justify-content: center;
}
 
.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: 
    radial-gradient(circle at 20% 80%, rgba(255, 255, 255, 0.1) 0%, transparent 20%),
    radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.1) 0%, transparent 20%);
}
 
.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 4rem 2rem;
}
 
.hero-title {
  font-size: 3.5rem;
  font-weight: 800;
  margin-bottom: 1rem;
  animation: slideIn 1s ease-out;
}
 
.hero-subtitle {
  font-size: 1.5rem;
  margin-bottom: 2rem;
  opacity: 0.9;
  animation: slideIn 1s ease-out 0.2s both;
}
 
.hero-cta {
  animation: slideIn 1s ease-out 0.4s both;
}
 
/* Footer */
footer {
  background: var(--dark);
  color: white;
  padding: 4rem 0 2rem;
  margin-top: 6rem;
  position: relative;
}
 
footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 5px;
  background: var(--gradient-primary);
}
 
.footer-links a {
  color: var(--gray);
  text-decoration: none;
  transition: var(--transition);
  display: block;
  margin-bottom: 0.5rem;
}
 
.footer-links a:hover {
  color: white;
  transform: translateX(5px);
}
 
.social-links {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-top: 2rem;
}
 
.social-links a {
  width: 45px;
  height: 45px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.1);
  color: white;
  font-size: 1.2rem;
  transition: var(--transition);
  text-decoration: none;
}
 
.social-links a:hover {
  background: var(--gradient-primary);
  transform: translateY(-3px);
}
 
/* ===== UI COMPONENTS ===== */
 
/* Cards */
.blog-post.card {
  border: none;
  border-radius: var(--radius);
  transition: var(--transition);
  box-shadow: var(--shadow-md);
  margin-bottom: 2.5rem;
  background: white;
  position: relative;
  animation: slideIn 0.6s ease-out;
}
 
.blog-post.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 5px;
  background: var(--gradient-primary);
}
 
.blog-post.card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-xl);
}
 
.card-body {
  padding: 2rem;
}
 
.card-title a {
  color: var(--dark);
  text-decoration: none;
  transition: var(--transition);
  font-weight: 700;
  font-size: 1.5rem;
  display: block;
  margin-bottom: 1rem;
}
 
.card-title a:hover {
  color: var(--primary);
  text-decoration: none;
}
 
/* Buttons */
.btn {
  border-radius: 50px;
  padding: 0.8rem 2rem;
  font-weight: 600;
  transition: var(--transition);
  border: none;
  position: relative;
  overflow: hidden;
}

.btn .ripple {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.6);
  width: 20px;
  height: 20px;
  margin-top: -10px;
  margin-left: -10px;
  animation: ripple-animation 0.6s ease-out;
  pointer-events: none;
}
 
.btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: var(--transition);
}
 
.btn:hover::before {
  left: 100%;
}
 
.btn-primary {
  background: var(--gradient-primary);
  box-shadow: var(--shadow-md);
}
 
.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
  animation: glow 2s infinite;
}
 
.btn-outline-primary {
  background: transparent;
  border: 2px solid var(--primary);
  color: var(--primary);
}
 
.btn-outline-primary:hover {
  background: var(--gradient-primary);
  color: white;
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}
 
/* Auth Buttons */
.auth-btn {
  width: 100%;
  background: var(--gradient-primary);
  border: none;
  border-radius: 12px;
  padding: 15px 20px;
  color: white;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  position: relative;
  overflow: hidden;
  text-decoration: none;
}
 
.auth-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s ease;
}
 
.auth-btn:hover::before {
  left: 100%;
}
 
.auth-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(102, 126, 234, 0.3);
}
 
.auth-btn:active {
  transform: translateY(0);
}
 
.auth-btn i {
  font-size: 1.2rem;
}
 
.auth-btn-outline {
  background: transparent;
  border: 2px solid #667eea;
  color: #667eea;
}
 
.auth-btn-outline:hover {
  background: #667eea;
  color: white;
}
 
.auth-btn-sm {
  padding: 10px 15px;
  font-size: 1rem;
}
 
.auth-btn-lg {
  padding: 20px 25px;
  font-size: 1.2rem;
}
 
.auth-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none !important;
  animation: none !important;
}
 
.auth-btn:disabled:hover {
  box-shadow: none;
}
 
/* Forms */
.form-control {
  border-radius: var(--radius);
  padding: 1rem 1.5rem;
  border: 2px solid #e5e7eb;
  transition: var(--transition);
  font-size: 1rem;
}
 
.form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
  transform: translateY(-2px);
}
 
/* Badges */
.post-count-badge {
  background: var(--gradient-primary);
  color: white !important;
  padding: 0.5rem 1rem;
  border-radius: 25px;
  font-weight: 600;
  font-size: 0.9rem;
  border: none;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-md);
}
 
.post-count-badge::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.6s ease;
}
 
.post-count-badge:hover::before {
  left: 100%;
}
 
.post-count-badge:hover {
  transform: translateY(-2px) scale(1.05);
  box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}
 
.post-count-badge i {
  margin-right: 0.3rem;
  font-size: 0.8rem;
}
 
.post-count-badge.sm {
  padding: 0.3rem 0.7rem;
  font-size: 0.8rem;
}
 
.post-count-badge.lg {
  padding: 0.7rem 1.3rem;
  font-size: 1rem;
}
 
/* ===== CONTENT STYLES ===== */
 
/* Post Content */
.blog-post-content {
  font-size: 1.1rem;
  line-height: 1.8;
  color: #2d3748;
  margin-top: 1.5rem;
}
 
.blog-post-content p {
  margin-bottom: 1.5rem;
}
 
.blog-post-content h2,
.blog-post-content h3,
.blog-post-content h4 {
  margin-top: 2rem;
  margin-bottom: 1rem;
  font-weight: 700;
  color: #2d3748;
}
 
.blog-post-content h2 {
  font-size: 1.8rem;
  border-bottom: 2px solid #e2e8f0;
  padding-bottom: 0.5rem;
}
 
.blog-post-content h3 {
  font-size: 1.5rem;
}
 
.blog-post-content h4 {
  font-size: 1.3rem;
}
 
.blog-post-content ul,
.blog-post-content ol {
  margin-bottom: 1.5rem;
  padding-left: 2rem;
}
 
.blog-post-content li {
  margin-bottom: 0.5rem;
}
 
.blog-post-content blockquote {
  border-left: 4px solid var(--primary);
  padding-left: 1.5rem;
  margin-left: 0;
  font-style: italic;
  color: #718096;
  background: #f7fafc;
  padding: 1.5rem;
  border-radius: 8px;
  margin: 1.5rem 0;
}
 
.blog-post-content code {
  background: #f7fafc;
  padding: 0.2rem 0.4rem;
  border-radius: 4px;
  font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
  font-size: 0.9em;
  color: #e53e3e;
}
 
.blog-post-content pre {
  background: #1a202c;
  color: #e2e8f0;
  padding: 1.5rem;
  border-radius: 8px;
  overflow-x: auto;
  margin: 1.5rem 0;
}
 
.blog-post-content pre code {
  background: none;
  color: inherit;
  padding: 0;
}
 
.blog-post-content img {
  max-width: 100%;
  height: auto;
  border-radius: 12px;
  margin: 1.5rem 0;
  box-shadow: var(--shadow-md);
}
 
.blog-post-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
}
 
.blog-post-content table th,
.blog-post-content table td {
  padding: 0.75rem;
  border: 1px solid #e2e8f0;
  text-align: left;
}
 
.blog-post-content table th {
  background: #f7fafc;
  font-weight: 600;
}
 
.blog-post-content table tr:nth-child(even) {
  background: #f7fafc;
}
 
.blog-post-content a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.3s ease;
}
 
.blog-post-content a:hover {
  color: var(--primary-dark);
  text-decoration: underline;
}
 
/* Post Header */
.blog-post-header {
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 2px solid #e2e8f0;
}
 
.blog-post-title {
  font-size: 2.5rem;
  font-weight: 800;
  color: #2d3748;
  margin-bottom: 1rem;
  line-height: 1.3;
}
 
.blog-post-meta {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  color: #718096;
  font-size: 0.9rem;
}
 
.blog-post-meta span {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
 
.blog-post-actions {
  display: flex;
  gap: 1rem;
}
 
/* Comments */
.comments-section {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 2px solid #e2e8f0;
}
 
.comment {
  border: none;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  background: white;
  margin-bottom: 1.5rem;
  position: relative;
}
 
.comment::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: var(--gradient-primary);
}
 
.comment:hover {
  transform: translateX(5px);
  box-shadow: var(--shadow-md);
}
 
.comment-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}
 
.comment-text {
  color: #4a5568;
  line-height: 1.6;
}
 
.add-comment {
  background: #f7fafc;
  padding: 2rem;
  border-radius: var(--radius);
  margin-top: 2rem;
}
 
/* Sidebar */
.sidebar-card {
  border: none;
  border-radius: 16px;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
  background: linear-gradient(145deg, #ffffff, #f8f9fa);
  position: relative;
  margin-bottom: 1.5rem;
}
 
.sidebar-card:last-child {
  margin-bottom: 0;
}
 
.sidebar-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gradient-primary);
  opacity: 0;
  transition: opacity 0.3s ease;
}
 
.sidebar-card:hover::before {
  opacity: 1;
}
 
.sidebar-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}
 
.sidebar-card .card-body {
  padding: 1.8rem;
  position: relative;
  z-index: 2;
}
 
.sidebar-title {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 1.2rem;
  display: flex;
  align-items: center;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  transition: var(--transition);
}
 
.sidebar-card:hover .sidebar-title {
  transform: translateX(5px);
}
 
.sidebar-title i {
  font-size: 1.2rem;
  margin-right: 0.5rem;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
 
.sidebar-text {
  color: #718096;
  line-height: 1.6;
  font-size: 1rem;
  margin-bottom: 0;
  transition: color 0.3s ease;
}
 
.sidebar-card:hover .sidebar-text {
  color: #4a5568;
}
 
/* Tags */
.tags-container {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}
 
.tag-badge {
  background: linear-gradient(135deg, #f7fafc 0%, #edf2f7 100%);
  color: #4a5568 !important;
  padding: 0.6rem 1rem;
  border-radius: 25px;
  font-weight: 500;
  font-size: 0.9rem;
  border: 2px solid transparent;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  cursor: pointer;
}
 
.tag-badge::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(102, 126, 234, 0.1), transparent);
  transition: left 0.6s ease;
}
 
.tag-badge:hover::before {
  left: 100%;
}
 
.tag-badge:hover {
  background: var(--gradient-primary);
  color: white !important;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
 
/* ===== UTILITIES ===== */
.gradient-text {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  display: inline-block;
}
 
.gradient-bg {
  background: var(--gradient-primary);
  background-size: 200% 200%;
  animation: gradientShift 3s ease infinite;
}
 
.shadow-hover {
  transition: var(--transition);
}
 
.shadow-hover:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-5px);
}
 
.animate-delay-1 { animation-delay: 0.1s; }
.animate-delay-2 { animation-delay: 0.2s; }
.animate-delay-3 { animation-delay: 0.3s; }
.animate-delay-4 { animation-delay: 0.4s; }
.animate-delay-5 { animation-delay: 0.5s; }
 
/* ===== SPECIAL EFFECTS ===== */
.particle-network {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
  z-index: -1;
}
 
.parallax-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    radial-gradient(circle at 15% 50%, rgba(99, 102, 241, 0.1) 0%, transparent 25%),
    radial-gradient(circle at 85% 30%, rgba(16, 185, 129, 0.1) 0%, transparent 25%);
  z-index: -2;
}
 
/* ===== FEATURES ===== */
.feature-icon {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gradient-primary);
  color: white;
  font-size: 1.8rem;
  margin: 0 auto 1.5rem;
  animation: float 3s ease-in-out infinite;
}
 
.feature-card {
  text-align: center;
  padding: 2rem;
  border-radius: var(--radius);
  background: white;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
  height: 100%;
}
 
.feature-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}
 
/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
  .hero-title {
    font-size: 2.5rem;
  }
 
  .hero-subtitle {
    font-size: 1.2rem;
  }
 
  .navbar-nav .nav-link {
    margin: 0.2rem 0;
    text-align: center;
  }
 
  .blog-post-content {
    font-size: 1rem;
  }
 
  .blog-post-content h2 {
    font-size: 1.5rem;
  }
 
  .blog-post-content h3 {
    font-size: 1.3rem;
  }
 
  .blog-post-content pre {
    padding: 1rem;
  }
 
  .blog-post-content table {
    font-size: 0.9rem;
  }
 
  .blog-post-title {
    font-size: 2rem;
  }
 
  .blog-post-meta {
    flex-direction: column;
    gap: 0.5rem;
  }
 
  .add-comment {
    padding: 1.5rem;
  }
 
  .tags-container {
    justify-content: center;
  }
 
  .tag-badge {
    padding: 0.5rem 0.8rem;
    font-size: 0.85rem;
  }
 
  .auth-btn {
    padding: 12px 16px;
    font-size: 1rem;
  }
 
  .auth-btn-lg {
    padding: 16px 20px;
    font-size: 1.1rem;
  }
 
  .post-count-badge {
    padding: 0.4rem 0.8rem;
    font-size: 0.85rem;
  }
 
  .post-count-badge.lg {
    padding: 0.6rem 1.1rem;
  }
}
 
@media (max-width: 992px) {
  .sidebar-card {
    margin-bottom: 1.5rem;
  }
 
  .sidebar-card .card-body {
    padding: 1.5rem;
  }
 
  .sidebar-title {
    font-size: 1.2rem;
  }
}