* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: #0f172a;
  color: #e2e8f0;
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* Header – Fully Responsive */
header {
  background: linear-gradient(135deg, #ec4899, #8b5cf6);
  color: white;
  text-align: center;
  padding: 4rem 1rem 3rem;
  position: relative;
  overflow: hidden;
}

h1 {
  font-size: clamp(2.5rem, 8vw, 4.5rem);   /* Scales perfectly on all screens */
  font-weight: 800;
  margin-bottom: 0.5rem;
  letter-spacing: -1px;
}

header p {
  font-size: clamp(1.1rem, 4vw, 1.4rem);
  opacity: 0.95;
  max-width: 800px;
  margin: 0 auto;
}

/* Language Switcher – Mobile Friendly */
.lang-switcher {
  position: absolute;
  top: 20px;
  right: 20px;
  z-index: 10;
}

#langSelect {
  padding: 0.65rem 1.3rem;
  border-radius: 50px;
  border: 2px solid rgba(255,255,255,0.3);
  background: rgba(255,255,255,0.2);
  backdrop-filter: blur(10px);
  color: white;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
}

#langSelect:hover {
  background: rgba(255,255,255,0.35);
  transform: scale(1.05);
}

/* Container */
.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 1.5rem;
}

/* Posts Grid – Super Responsive */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr));
  gap: clamp(1rem, 3vw, 2rem);
  margin: 2rem 0;
}

/* Post Card – Modern Glassmorphism */
.post {
  background: rgba(30, 41, 59, 0.7);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.1);
}

.post:hover {
  transform: translateY(-16px) scale(1.02);
  box-shadow: 0 20px 40px rgba(0,0,0,0.6);
}

.post img {
  width: 100%;
  height: clamp(180px, 35vw, 240px);
  object-fit: cover;
  background: #334155;
  display: block;
}

.content {
  padding: clamp(1rem, 3vw, 1.8rem);
}

.title {
  font-size: clamp(1.15rem, 4vw, 1.4rem);
  font-weight: 700;
  margin: 0.6rem 0;
  color: #f8fafc;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.meta {
  font-size: 0.85rem;
  color: #94a3b8;
  margin-bottom: 0.6rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.excerpt {
  color: #cbd5e1;
  font-size: 0.95rem;
  margin-bottom: 1rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.read {
  background: linear-gradient(135deg, #ec4899, #d946ef);
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 50px;
  cursor: pointer;
  font-weight: 700;
  font-size: 0.95rem;
  transition: all 0.3s ease;
  width: 100%;
  margin-top: 0.5rem;
}

.read:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(236, 72, 153, 0.4);
}

/* Ads */
.ad-banner, .ad-bottom {
  text-align: center;
  margin: 3rem 0;
  padding: 1.5rem;
  background: rgba(255,255,255,0.05);
  border-radius: 16px;
  backdrop-filter: blur(8px);
}

/* Loading State */
#loading {
  text-align: center;
  padding: 5rem 1rem;
  font-size: 1.5rem;
  color: #94a3b8;
}

/* Mobile Optimizations */
@media (max-width: 768px) {
  header { padding: 3.5rem 1rem 2.5rem; }
  .lang-switcher {
    position: static;
    margin: 1rem auto;
    text-align: center;
  }
  #langSelect {
    width: 85%;
    max-width: 300px;
  }
  .posts-grid { gap: 1.5rem; }
  .post img { height: 200px; }
}

@media (max-width: 480px) {
  .posts-grid {
    grid-template-columns: 1fr;
    gap: 1.8rem;
  }
  .post img { height: 220px; }
}