/* ========================================
   PaaS Blog - Platform as a Service Styles
   ======================================== */

/* CSS Variables */
:root {
  /* Primary Colors - Deep Blue to Purple Gradient */
  --primary-start: #1e3a5f;
  --primary-end: #7c3aed;
  --primary-gradient: linear-gradient(135deg, #1e3a5f 0%, #7c3aed 100%);

  /* Accent Color - Bright Tech Blue */
  --accent: #3b82f6;
  --accent-light: #60a5fa;
  --accent-dark: #2563eb;

  /* Background Colors - Dark Tech Theme */
  --bg-primary: #0f172a;
  --bg-secondary: #1e293b;
  --bg-card: #1e293b;

  /* Text Colors */
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --text-light: #f8fafc;

  /* Border & Shadow */
  --border-radius: 12px;
  --border-radius-sm: 8px;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.5);
  --shadow-hover: 0 12px 32px rgba(124, 58, 237, 0.3);

  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;
}

/* Reset & Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  font-size: 16px;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color var(--transition-fast);
}

ul, ol {
  list-style: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ========================================
   Navigation
   ======================================== */
.navbar {
  background: var(--primary-gradient);
  padding: 1rem 2rem;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  box-shadow: var(--shadow-md);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-light);
}

.nav-logo .logo-icon {
  font-size: 1.75rem;
}

.nav-logo:hover {
  transform: scale(1.02);
}

.nav-links {
  display: flex;
  gap: 2rem;
}

.nav-links a {
  color: var(--text-light);
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: var(--border-radius-sm);
  transition: all var(--transition-fast);
  position: relative;
}

.nav-links a:hover {
  background: rgba(255, 255, 255, 0.15);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  cursor: pointer;
  gap: 5px;
}

.nav-toggle span {
  width: 25px;
  height: 3px;
  background: var(--text-light);
  border-radius: 2px;
  transition: var(--transition-fast);
}

/* ========================================
   Hero Section
   ======================================== */
.hero {
  background: var(--primary-gradient);
  padding: 8rem 2rem 4rem;
  text-align: center;
  color: var(--text-light);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  opacity: 0.5;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 800px;
  margin: 0 auto;
}

.hero-icon {
  font-size: 4rem;
  margin-bottom: 1.5rem;
  display: inline-block;
  animation: float 3s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.hero h1 {
  font-size: 3rem;
  font-weight: 800;
  margin-bottom: 1rem;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.hero p {
  font-size: 1.25rem;
  opacity: 0.95;
  margin-bottom: 2rem;
  line-height: 1.8;
}

.hero-stats {
  display: flex;
  justify-content: center;
  gap: 3rem;
  margin-top: 2rem;
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.stat-icon {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
}

.stat-number {
  font-size: 2rem;
  font-weight: 700;
}

.stat-label {
  font-size: 0.875rem;
  opacity: 0.9;
}

/* ========================================
   Main Container
   ======================================== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 3rem 2rem;
}

/* ========================================
   Section Titles
   ======================================== */
.section-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid var(--primary-start);
  font-size: 1.75rem;
  color: var(--text-primary);
  font-weight: 700;
}

.section-title::before {
  content: '◆';
  color: var(--accent);
  font-size: 1.5rem;
}

.section-icon {
  font-size: 1.75rem;
}

/* ========================================
   Article Cards
   ======================================== */
.articles-section {
  margin-bottom: 4rem;
}

.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2rem;
}

.article-card {
  background: var(--bg-card);
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-normal);
  cursor: pointer;
  border: 1px solid rgba(124, 58, 237, 0.2);
}

.article-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: var(--accent);
}

.article-image {
  height: 200px;
  background: var(--primary-gradient);
  position: relative;
  overflow: hidden;
}

.article-image-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 4rem;
  opacity: 0.3;
}

.article-content {
  padding: 1.5rem;
}

.article-category {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  background: var(--accent);
  color: var(--text-light);
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.75rem;
}

.article-card h3 {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
  color: var(--text-primary);
  line-height: 1.4;
}

.article-card h3:hover {
  color: var(--accent);
}

.article-excerpt {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: 1rem;
  line-height: 1.7;
}

.article-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text-muted);
  font-size: 0.875rem;
}

.article-date {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.article-read-time {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* ========================================
   Categories Grid
   ======================================== */
.categories-section {
  margin-bottom: 4rem;
}

.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}

.category-card {
  background: var(--bg-card);
  border-radius: var(--border-radius);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-normal);
  cursor: pointer;
  text-decoration: none;
  display: block;
  border: 1px solid transparent;
}

.category-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: var(--accent);
}

.category-card h3 {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.category-card p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.6;
}

.category-count {
  display: inline-block;
  padding: 4px 12px;
  background: rgba(59, 130, 246, 0.2);
  color: var(--accent);
  border-radius: 12px;
  font-size: 0.8rem;
  margin-top: 12px;
}

/* ========================================
   Links Section
   ======================================== */
.links-section {
  margin-bottom: 4rem;
}

.links-title {
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 24px;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 12px;
}

.links-title::before {
  content: '◆';
  color: var(--accent);
}

.links-list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.link-item {
  display: inline-block;
  padding: 8px 16px;
  background: var(--bg-card);
  border: 1px solid var(--bg-secondary);
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.9rem;
  border-radius: 20px;
  transition: all var(--transition-fast);
}

.link-item:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(59, 130, 246, 0.1);
}

/* ========================================
   Footer
   ======================================== */
.footer {
  background: #020617;
  color: var(--text-light);
  padding: 3rem 2rem 1.5rem;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 2rem;
}

.footer-brand {
  max-width: 300px;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.footer-logo-icon {
  font-size: 1.75rem;
}

.footer-brand p {
  color: var(--text-muted);
  line-height: 1.7;
}

.footer-column h4 {
  font-size: 1.1rem;
  margin-bottom: 1rem;
  color: var(--text-light);
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-links a {
  color: var(--text-muted);
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--accent);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1.5rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.875rem;
}

.footer-bottom a {
  color: var(--accent);
}

/* ========================================
   Hero Tags
   ======================================== */
.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-top: 24px;
}

.tag {
  display: inline-block;
  padding: 6px 14px;
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  border-radius: 20px;
  font-size: 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* ========================================
   Responsive Design
   ======================================== */
@media (max-width: 1200px) {
  .container {
    padding: 2rem 1.5rem;
  }

  .hero h1 {
    font-size: 2.5rem;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
}

@media (max-width: 768px) {
  .navbar {
    padding: 1rem;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--primary-end);
    flex-direction: column;
    padding: 1rem;
    gap: 0.5rem;
  }

  .nav-links.active {
    display: flex;
  }

  .nav-toggle {
    display: flex;
  }

  .hero {
    padding: 6rem 1rem 3rem;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .hero p {
    font-size: 1rem;
  }

  .hero-stats {
    flex-direction: column;
    gap: 1.5rem;
  }

  .container {
    padding: 2rem 1rem;
  }

  .articles-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    text-align: center;
  }

  .footer-brand {
    max-width: 100%;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 1.75rem;
  }

  .stat-number {
    font-size: 1.5rem;
  }

  .article-card h3 {
    font-size: 1.1rem;
  }
}