:root {
  --bg-color: #050505;
  --text-color: #fafafa;
  --text-dim: #a0a0a0;
  --accent-color: #ffffff;
  --border-color: #333;
  --transition-speed: 0.5s;
  --font-main: "Helvetica Neue", Arial, sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-color);
  color: var(--text-color);
  font-family: var(--font-main);
  line-height: 1.6;
  overflow-x: hidden;
  opacity: 0;
  animation: fadeIn 0.5s ease-out forwards;
}

a {
  color: inherit;
  text-decoration: none;
  transition: opacity 0.3s;
}

a:hover {
  opacity: 0.7;
}

ul {
  list-style: none;
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInRight {
  from {
    transform: translateX(100%);
  }
  to {
    transform: translateX(0);
  }
}

.page-transition {
  animation: fadeIn 0.4s ease-out;
}

/* Layout */
.container {
  max-width: 800px;
  margin: 0 auto;
  padding: 2rem;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4rem;
  padding-top: 2rem;
}

.logo {
  font-size: 1.5rem;
  font-weight: bold;
  letter-spacing: -0.5px;
}

/* Search */
.search-container {
  margin-bottom: 3rem;
  position: relative;
}

.search-input {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-color);
  font-size: 1.2rem;
  padding: 0.5rem 0;
  outline: none;
  transition: border-color 0.3s;
}

.search-input:focus {
  border-bottom-color: var(--accent-color);
}

.search-input::placeholder {
  color: #444;
}

/* Blog List */
.blog-list {
  display: grid;
  gap: 3rem;
  flex: 1;
}

.blog-item {
  cursor: pointer;
  transition: transform 0.3s ease;
  border-bottom: 1px solid #111; /* subtle separator */
  padding-bottom: 2rem;
}

.blog-item:hover {
  transform: translateX(5px);
}

.blog-date {
  font-size: 0.85rem;
  color: var(--text-dim);
  margin-bottom: 0.5rem;
  display: block;
}

.blog-title {
  font-size: 1.8rem;
  margin-bottom: 0.8rem;
  font-weight: 500;
}

.blog-excerpt {
  color: var(--text-dim);
  font-size: 1rem;
}

.blog-thumbnail {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 4px;
  margin-bottom: 1rem;
  transition: opacity 0.3s;
}

.blog-item:hover .blog-thumbnail {
  opacity: 0.8;
}

/* Hamburger Menu */
.menu-btn {
  position: fixed;
  top: 2rem;
  right: 2rem;
  z-index: 100;
  cursor: pointer;
  width: 30px;
  height: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.menu-btn span {
  display: block;
  height: 2px;
  width: 100%;
  background-color: var(--text-color);
  transition: all 0.3s ease;
}

/* Menu State: Open */
body.menu-open .menu-btn span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
body.menu-open .menu-btn span:nth-child(2) {
  opacity: 0;
}
body.menu-open .menu-btn span:nth-child(3) {
  transform: rotate(-45deg) translate(8px, -8px); /* adjusted for alignment */
}

.nav-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--bg-color);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 99;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}

body.menu-open .nav-overlay {
  opacity: 1;
  pointer-events: auto;
}

.nav-links {
  text-align: center;
  font-size: 2rem;
}

.nav-links li {
  margin: 1.5rem 0;
  overflow: hidden; /* for reveal effect if needed */
}

.nav-links a {
  display: inline-block;
  position: relative;
}

.nav-links a::after {
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -5px;
  left: 0;
  background-color: var(--accent-color);
  transition: width 0.3s;
}

.nav-links a:hover::after {
  width: 100%;
}

/* Blog Post Page Styles */
.post-header {
  margin-bottom: 3rem;
}
.post-title {
  font-size: 2.5rem;
  line-height: 1.2;
  margin-bottom: 1rem;
}
.post-image {
  width: 100%;
  height: auto;
  border-radius: 4px;
  margin-bottom: 2rem;
  /* Grayscale removed as per user request */
  transition: opacity 0.5s;
}
.post-image:hover {
  opacity: 0.9;
}
.post-content {
  font-size: 1.1rem;
  line-height: 1.8;
  color: #ddd;
}
.post-content p {
  margin-bottom: 1.5rem;
}
