/* blog.css */

:root {
  --deep-indigo: #4B0082;
  --soft-lavender: #B57EDC;
  --misty-teal: #5F9EA0;
  --sage-green: #8A9A5B;
  --warm-sand: #E6D3A7;
  --gradient: linear-gradient(to right, var(--deep-indigo), var(--soft-lavender), var(--misty-teal), var(--sage-green), var(--warm-sand));
  --glass: rgba(255, 255, 255, 0.2);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
  background: linear-gradient(135deg, #f3e5f5, #e1f5fe, #e0f7fa);
  background-size: 400% 400%;
  animation: gradientFlow 15s ease infinite;
  color: #1f1f1f;
  padding: 20px;
}

@keyframes gradientFlow {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}
.blog-header {
  text-align: center;
  margin-bottom: 30px;
}

.blog-header h1 {
  font-size: 3rem;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: transparent;
  margin-bottom: 10px;
  animation: pulse 3s infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.03); }
}

.blog-header p {
  font-size: 1.2rem;
  color: #555;
}

.blog-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  margin-bottom: 30px;
  flex-wrap: wrap;
}

#search-bar,
#topic-select {
  padding: 12px 18px;
  font-size: 1rem;
  border-radius: 30px;
  border: 2px solid var(--misty-teal);
  outline: none;
  transition: all 0.3s ease;
  background: var(--glass);
  backdrop-filter: blur(8px);
}

#search-bar:focus,
#topic-select:focus {
  border-color: var(--deep-indigo);
  background: white;
}

#blog-posts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 25px;
  padding: 30px 20px;
}

/* Updated anchor style for each post */
a.post {
  display: block;
  padding: 24px 28px;
  margin: 10px auto;
  max-width: 700px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(14px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
  color: #fff;
  text-decoration: none;
  transition: all 0.4s ease;
  font-size: 1.15rem;
  font-weight: 600;
  line-height: 1.6;
  position: relative;
  overflow: hidden;
  background-image: linear-gradient(120deg, rgba(75,0,130,0.1), rgba(255,255,255,0.04));
  border: 2px solid transparent;
}

/* Fancy shimmer overlay */
a.post::before {
  content: '';
  position: absolute;
  top: -100%;
  left: -100%;
  width: 300%;
  height: 300%;
  background: linear-gradient(135deg, rgba(255,255,255,0.2), rgba(255,255,255,0));
  transform: rotate(45deg);
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 0;
}

/* Hover interaction with glow effect */
a.post:hover {
  transform: scale(1.03);
  background: linear-gradient(135deg, #5F9EA0, #B57EDC, #4B0082);
  color: #fff;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.25);
  border: 2px solid rgba(255, 255, 255, 0.2);
}

a.post:hover::before {
  opacity: 1;
}

/* Gradient-text for strong titles */
a.post strong {
  background: linear-gradient(to right, #ffffff, #ffd700, #B57EDC);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 800;
  display: inline-block;
  text-shadow: none;
}

/* Responsive tweaks */
@media (max-width: 600px) {
  a.post {
    padding: 20px;
    font-size: 1rem;
  }
}


  .blog-header h1 {
    font-size: 2rem;
  }

.mega-footer {
  background: #1a1a1a;
  color: #eee;
  padding: 80px 40px 30px;
  font-family: 'Inter', sans-serif;
}

.footer-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
}

.footer-brand h2 {
  font-size: 2rem;
  background: linear-gradient(90deg, #4B0082, #B57EDC, #5F9EA0);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.footer-brand p {
  font-size: 0.95rem;
  line-height: 1.6;
  margin-top: 10px;
  opacity: 0.85;
}

.footer-links h3,
.footer-contact h3,
.footer-legal h3,
.footer-newsletter h3 {
  margin-bottom: 10px;
  font-size: 1.2rem;
  color: #fff;
}

.footer-links ul,
.footer-legal ul {
  list-style: none;
  padding: 0;
}

.footer-links ul li,
.footer-legal ul li {
  margin-bottom: 8px;
}

.footer-links ul li a,
.footer-legal ul li a {
  color: #ccc;
  text-decoration: none;
  transition: color 0.3s;
}

.footer-links ul li a:hover,
.footer-legal ul li a:hover {
  color: #B57EDC;
}

.footer-contact p {
  font-size: 0.95rem;
  margin-bottom: 6px;
  opacity: 0.85;
}

.footer-newsletter p {
  font-size: 0.95rem;
  margin-bottom: 10px;
}

.footer-newsletter form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-newsletter input {
  padding: 10px;
  border-radius: 25px;
  border: none;
  outline: none;
}

.footer-newsletter button {
  background: linear-gradient(to right, #5F9EA0, #8A9A5B);
  color: white;
  border: none;
  border-radius: 25px;
  padding: 10px;
  font-weight: bold;
  cursor: pointer;
  transition: background 0.3s ease;
}

.footer-newsletter button:hover {
  background: linear-gradient(to right, #8A9A5B, #5F9EA0);
}

.footer-bottom {
  text-align: center;
  font-size: 0.9rem;
  color: #aaa;
  border-top: 1px solid #333;
  padding-top: 20px;
}
a.post {
  display: block;
  padding: 20px 25px;
  margin: 15px auto;
  max-width: 700px;
  border-radius: 14px;
  background: linear-gradient(135deg, #ffffff, #f7f7f7);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
  color: #1f1f1f;
  text-decoration: none;
  transition: all 0.3s ease;
  font-size: 1.1rem;
  font-weight: 600;
  line-height: 1.6;
  position: relative;
  overflow: hidden;
}

a.post:hover {
  transform: translateY(-4px) scale(1.02);
  background: linear-gradient(135deg, #B57EDC, #5F9EA0);
  color: #fff;
  box-shadow: 0 10px 25px rgba(75, 0, 130, 0.3);
}

a.post strong {
  color: inherit;
  font-weight: 800;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

a.post::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(255,255,255,0.1), rgba(0,0,0,0.05));
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 0;
}

a.post:hover::before {
  opacity: 1;
}

@media (max-width: 600px) {
  a.post {
    font-size: 1rem;
    padding: 16px 18px;
  }
}
.floating-emojis {
  position: fixed;
  pointer-events: none;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 999;
}

.floating-emojis span {
  position: absolute;
  display: inline-block;
  font-size: 1.5rem;
  animation: floatEmoji 10s linear infinite;
  opacity: 0.7;
}

@keyframes floatEmoji {
  0% {
    transform: translateY(100vh) rotate(0deg);
    opacity: 0;
  }
  50% {
    opacity: 1;
  }
  100% {
    transform: translateY(-10vh) rotate(360deg);
    opacity: 0;
  }
}

/* Random position and delay */
.floating-emojis span:nth-child(1) { left: 5%; animation-delay: 0s; }
.floating-emojis span:nth-child(2) { left: 20%; animation-delay: 2s; }
.floating-emojis span:nth-child(3) { left: 40%; animation-delay: 4s; }
.floating-emojis span:nth-child(4) { left: 60%; animation-delay: 1s; }
.floating-emojis span:nth-child(5) { left: 75%; animation-delay: 3s; }
.floating-emojis span:nth-child(6) { left: 90%; animation-delay: 5s; }
.floating-emojis span:nth-child(7) { left: 35%; animation-delay: 6s; }
.floating-emojis span:nth-child(8) { left: 13%; animation-delay: 7s; }