:root {
  --bg-color: #000000;
  --text-primary: #00ff00;
  --text-dim: #008800;
  --border-color: #00ff00;
}

body {
  margin: 0;
  padding: 2rem;
  background-color: var(--bg-color);
  color: var(--text-primary);
  font-family: 'Courier New', Courier, monospace;
  line-height: 1.4;
  /* Removed CRT effects for clarity */
}

/* Removed @keyframes flicker */

h1.terminal-header {
  border-bottom: 2px solid var(--border-color);
  padding-bottom: 1rem;
  margin-bottom: 2rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  position: relative;
  display: inline-block;
}

/* Blinking Cursor - Kept because it's cool and doesn't hurt reading */
h1.terminal-header::after {
  content: ' _';
  animation: blink 1s step-end infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.terminal-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.terminal-item {
  border: 1px solid var(--text-dim);
  padding: 1rem;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  /* Typing entrance animation */
  animation: slideIn 0.5s ease-out forwards;
  opacity: 0;
  transform: translateX(-20px);
  background: #000; /* Ensure solid background for text contrast */
}

/* Staggered animation for items */
.terminal-item:nth-child(1) { animation-delay: 0.1s; }
.terminal-item:nth-child(2) { animation-delay: 0.2s; }
.terminal-item:nth-child(3) { animation-delay: 0.3s; }
.terminal-item:nth-child(4) { animation-delay: 0.4s; }
.terminal-item:nth-child(5) { animation-delay: 0.5s; }
/* ... more can be added if list is long ... */

@keyframes slideIn {
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.terminal-item:hover {
  border-color: var(--text-primary);
  box-shadow: 0 0 15px var(--text-primary);
  background: rgba(0, 255, 0, 0.1);
  transform: translateX(5px) scale(1.01);
}

.item-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  border-bottom: 1px dashed var(--text-dim);
  padding-bottom: 0.5rem;
  margin-bottom: 0.5rem;
}

.date {
  font-weight: bold;
}

.title {
  text-transform: uppercase;
}

.summary {
  color: #cccccc; /* Slightly readable text for summary */
  font-size: 0.9em;
}

/* Modal / Details View */
.modal-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.9);
  z-index: 100;
  justify-content: center;
  align-items: center;
}

.modal-content {
  background: #000;
  border: 2px solid #00ff00;
  padding: 2rem;
  width: 80%;
  max-width: 800px;
  max-height: 80vh;
  overflow-y: auto;
  position: relative;
  box-shadow: 0 0 50px rgba(0, 255, 0, 0.2);
}

.close-btn {
  position: absolute;
  top: 1rem;
  right: 1rem;
  cursor: pointer;
  font-size: 1.5rem;
  color: #00ff00;
}

.modal-content img {
    max-width: 100%;
    border: 1px solid #00ff00;
}

/* ... existing styles ... */

/* Mobile Responsiveness */
@media (max-width: 600px) {
  body {
    padding: 1rem;
    font-size: 14px; /* Slightly smaller base font */
  }

  h1.terminal-header {
    font-size: 1.5rem; /* Smaller header */
    margin-bottom: 1rem;
  }

  .terminal-item {
    padding: 0.8rem;
  }

  .item-header {
    flex-direction: column; /* Stack date and title */
    gap: 0.2rem;
    align-items: flex-start;
  }

  .date {
    font-size: 0.8em;
    color: var(--text-dim);
  }

  .modal-content {
    width: 95%; /* Use full width on mobile */
    padding: 1rem; /* Less padding */
    max-height: 90vh;
  }

  .close-btn {
    top: 0.5rem;
    right: 0.5rem;
    padding: 0.5rem; /* Larger touch target area */
  }
}
