/* Global */
body {
  margin: 0;
  font-family: 'Poppins', sans-serif;
  background: #f9f9f9;
  color: #333;
  transition: background 0.3s, color 0.3s;
}
a { text-decoration: none; color: inherit; }

/* Header */
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #222;
  color: #fff;
  padding: 15px 20px;
}
.logo { font-size: 24px; font-weight: 600; }
.nav-links { list-style: none; display: flex; gap: 20px; }
.nav-links li a { color: #fff; font-weight: 500; }
#darkModeToggle {
  background: transparent;
  border: none;
  color: #fff;
  font-size: 20px;
  cursor: pointer;
}

/* Hero Section */
.hero {
    position: relative;
  background: url('https://source.unsplash.com/1600x500/?blog,technology') center/cover no-repeat;
  color: white;
  text-align: center;
  padding: 100px 20px;
  border-radius: 0;
}

.hero::before {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(9, 9, 7, 0.5); /* semi-transparent black */
  z-index: 1;
}

.hero h1 { font-size: 40px; margin-bottom: 10px; position: relative; z-index: 2; }
.hero p { font-size: 18px; position: relative; z-index: 2; }

/* Layout */
.container {
  display: grid;
  grid-template-columns: 3fr 1fr;
  gap: 20px;
  padding: 20px;
  max-width: 1200px;
  margin: auto;
}

/* Blog Posts */
.post {
  background: #fff;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 3px 8px rgba(0,0,0,0.1);
  margin-bottom: 20px;
  transition: transform 0.2s;
}
.post:hover { transform: translateY(-4px); }
.post img {
  width: 50%;
  border-radius: 8px;
  margin-bottom: 15px;
}
.post h2 { margin-top: 0; }
.read-more {
  color: #0077cc;
  cursor: pointer;
  font-weight: bold;
}
.more-text { display: none; }

/* Sidebar */
aside {
  background: #fff;
  padding: 15px;
  border-radius: 12px;
  box-shadow: 0 3px 8px rgba(0,0,0,0.1);
  height: fit-content;
}
aside h3 { margin-top: 0; }
aside ul { list-style: none; padding: 0; }
aside ul li { margin: 10px 0; }
aside ul li a { color: #333; }
aside ul li a:hover { color: #0077cc; }

/* Footer */
footer {
  background: #222;
  color: #fff;
  text-align: center;
  padding: 20px;
}
footer .socials {
  margin-top: 10px;
}
footer .socials a {
  margin: 0 10px;
  color: #fff;
  font-weight: 500;
}
footer .socials a:hover { color: #0077cc; }

/* Dark Mode */
.dark {
  background: #111;
  color: #eee;
}
.dark header { background: #000; }
.dark footer { background: #000; }
.dark .post, .dark aside { background: #1e1e1e; }
.dark .read-more { color: #4da3ff; }

/* Responsive */
@media(max-width: 768px) {
  .container { grid-template-columns: 1fr; }
  .nav-links { display: none; }
}
