@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Outfit:wght@400;600;700&display=swap');

:root {
  /* Color Palette */
  --primary-color: hsl(220, 95%, 60%);
  --primary-dark: hsl(220, 95%, 50%);
  --primary-light: hsl(220, 95%, 70%);
  --accent-color: hsl(280, 75%, 65%);
  --bg-primary: hsl(220, 25%, 97%);
  --bg-secondary: hsl(0, 0%, 100%);
  --text-primary: hsl(220, 20%, 20%);
  --text-secondary: hsl(220, 15%, 45%);
  --text-muted: hsl(220, 10%, 60%);
  --border-color: hsl(220, 20%, 90%);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.12);
  --gradient-primary: linear-gradient(135deg, hsl(220, 95%, 60%), hsl(280, 75%, 65%));
  --gradient-subtle: linear-gradient(180deg, hsl(0, 0%, 100%), hsl(220, 25%, 97%));
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  line-height: 1.7;
  color: var(--text-primary);
  background: var(--bg-primary);
  font-size: 16px;
}

/* Header & Navigation */
header {
  background: var(--bg-secondary);
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(10px);
  background: rgba(255, 255, 255, 0.95);
}

nav {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1.2rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-family: 'Outfit', sans-serif;
  font-size: 1.8rem;
  font-weight: 700;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  cursor: pointer;
  transition: transform 0.3s ease;
}

.logo:hover {
  transform: scale(1.05);
}

.nav-links {
  display: flex;
  gap: 2rem;
  list-style: none;
}

.nav-links a {
  text-decoration: none;
  color: var(--text-secondary);
  font-weight: 500;
  transition: color 0.3s ease;
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gradient-primary);
  transition: width 0.3s ease;
}

.nav-links a:hover {
  color: var(--primary-color);
}

.nav-links a:hover::after {
  width: 100%;
}

/* Mobile Menu Toggle */
.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
  background: transparent;
  border: none;
}

.menu-toggle span {
  width: 25px;
  height: 3px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: all 0.3s ease;
}

/* Hero Section */
.hero {
  background: var(--gradient-primary);
  color: white;
  padding: 5rem 2rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg width="60" height="60" xmlns="http://www.w3.org/2000/svg"><rect width="1" height="1" fill="rgba(255,255,255,0.1)"/></svg>');
  opacity: 0.3;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.hero h1 {
  font-family: 'Outfit', sans-serif;
  font-size: 3.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
  animation: fadeInUp 0.8s ease;
}

.hero p {
  font-size: 1.3rem;
  opacity: 0.95;
  animation: fadeInUp 0.8s ease 0.2s both;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Main Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 3rem 2rem;
}

/* Blog Grid */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.blog-card {
  background: var(--bg-secondary);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
  cursor: pointer;
  border: 1px solid var(--border-color);
}

.blog-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.blog-card-header {
  height: 200px;
  background: var(--gradient-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.blog-card-header::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.2) 0%, transparent 70%);
  animation: rotate 20s linear infinite;
}

@keyframes rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.blog-icon {
  font-size: 4rem;
  z-index: 1;
}

.blog-card-body {
  padding: 1.5rem;
}

.blog-card-body h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.4rem;
  margin-bottom: 0.8rem;
  color: var(--text-primary);
  line-height: 1.4;
}

.blog-excerpt {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: 1rem;
  line-height: 1.6;
}

.blog-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 1rem;
  border-top: 1px solid var(--border-color);
}

.read-time {
  color: var(--text-muted);
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.read-more {
  color: var(--primary-color);
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.3rem;
  transition: gap 0.3s ease;
}

.read-more:hover {
  gap: 0.6rem;
}

/* Blog Post Page */
.blog-post {
  max-width: 800px;
  margin: 0 auto;
  background: var(--bg-secondary);
  padding: 3rem;
  border-radius: 16px;
  box-shadow: var(--shadow-md);
  margin-top: 2rem;
}

.post-header {
  text-align: center;
  margin-bottom: 2rem;
  padding-bottom: 2rem;
  border-bottom: 2px solid var(--border-color);
}

.post-header h1 {
  font-family: 'Outfit', sans-serif;
  font-size: 2.5rem;
  line-height: 1.3;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.post-meta {
  color: var(--text-muted);
  font-size: 0.95rem;
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  align-items: center;
}

.post-content {
  color: var(--text-primary);
  font-size: 1.1rem;
  line-height: 1.8;
}

.post-content h2 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.8rem;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.post-content h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.4rem;
  margin-top: 2rem;
  margin-bottom: 0.8rem;
  color: var(--text-primary);
}

.post-content p {
  margin-bottom: 1.2rem;
  max-width: 100%;
}

.post-content ul,
.post-content ol {
  margin: 1.5rem 0;
  padding-left: 2rem;
}

.post-content li {
  margin-bottom: 0.8rem;
}

.pro-tip {
  background: linear-gradient(135deg, hsl(45, 100%, 96%), hsl(45, 100%, 92%));
  border-left: 4px solid hsl(45, 100%, 50%);
  padding: 1.5rem;
  margin: 2rem 0;
  border-radius: 8px;
  box-shadow: var(--shadow-sm);
}

.pro-tip-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  color: hsl(45, 100%, 35%);
  margin-bottom: 0.8rem;
  font-size: 1.1rem;
}

.pro-tip-icon {
  font-size: 1.3rem;
}

.pro-tip p {
  color: var(--text-primary);
  margin-bottom: 0;
}

/* Back Button */
.back-button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 500;
  margin-bottom: 2rem;
  padding: 0.8rem 1.5rem;
  border-radius: 8px;
  transition: all 0.3s ease;
  background: var(--bg-primary);
}

.back-button:hover {
  background: var(--border-color);
  color: var(--primary-color);
  transform: translateX(-5px);
}

/* Footer */
footer {
  background: var(--text-primary);
  color: white;
  text-align: center;
  padding: 2rem;
  margin-top: 4rem;
}

footer p {
  opacity: 0.9;
  font-size: 0.95rem;
}

/* Responsive Design */
@media (max-width: 768px) {
  .menu-toggle {
    display: flex;
  }

  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--bg-secondary);
    box-shadow: var(--shadow-md);
    padding: 1rem 2rem;
    gap: 1rem;
    transform: translateY(-200%);
    opacity: 0;
    transition: all 0.3s ease;
    pointer-events: none;
  }

  .nav-links.active {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
  }

  .hero h1 {
    font-size: 2.5rem;
  }

  .hero p {
    font-size: 1.1rem;
  }

  .blog-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .blog-post {
    padding: 2rem 1.5rem;
    margin-top: 1rem;
  }

  .post-header h1 {
    font-size: 2rem;
  }

  .post-content {
    font-size: 1rem;
  }

  .post-content h2 {
    font-size: 1.5rem;
  }

  .post-content h3 {
    font-size: 1.2rem;
  }

  .post-meta {
    flex-direction: column;
    gap: 0.5rem;
  }
}

@media (max-width: 480px) {
  nav {
    padding: 1rem;
  }

  .logo {
    font-size: 1.5rem;
  }

  .hero {
    padding: 3rem 1rem;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .container {
    padding: 2rem 1rem;
  }
}
