* {
  font-family: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

body.dark {
  background-color: #111827;
}

@keyframes bounce-in {
  0% { transform: translateX(-50%) translateY(20px); opacity: 0; }
  50% { transform: translateX(-50%) translateY(-5px); }
  100% { transform: translateX(-50%) translateY(0); opacity: 1; }
}

.animate-bounce-in {
  animation: bounce-in 0.3s ease-out;
}

/* Reddit Content Styling */
.reddit-content {
  font-size: 14px;
  line-height: 1.5;
}

.reddit-content.dark-mode {
  background: #1a1a1b;
  color: #d7dadc;
}

.reddit-content.light-mode {
  background: #ffffff;
  color: #1c1c1c;
}

/* Subreddit Container */
.reddit-content .subreddit-container {
  padding: 1rem;
}

@media (min-width: 768px) {
  .reddit-content .subreddit-container {
    padding: 1.5rem;
  }
}

/* Header Area */
.reddit-content .subreddit-header {
  background: linear-gradient(135deg, #ff4500 0%, #ff6b35 100%);
  padding: 1.5rem;
  border-radius: 8px;
  margin-bottom: 1rem;
  color: white;
}

.dark-mode .subreddit-header {
  background: linear-gradient(135deg, #ff4500 0%, #cc3700 100%);
}

/* Stats */
.reddit-content .subreddit-stats {
  display: flex;
  gap: 1rem;
  padding: 0.75rem 0;
  font-size: 13px;
  border-bottom: 1px solid;
  margin-bottom: 1rem;
}

.dark-mode .subreddit-stats {
  border-color: #343536;
  color: #818384;
}

.light-mode .subreddit-stats {
  border-color: #edeff1;
  color: #7c7c7c;
}

/* About Section */
.reddit-content .subreddit-about {
  padding: 1rem;
  border-radius: 8px;
  margin-bottom: 1rem;
}

.dark-mode .subreddit-about {
  background: #272729;
}

.light-mode .subreddit-about {
  background: #f6f7f8;
}

/* Posts Container */
.reddit-content .posts-container {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

/* Individual Post */
.reddit-content .post-card {
  padding: 1rem;
  border-radius: 8px;
  border: 1px solid;
  transition: border-color 0.2s;
}

.dark-mode .post-card {
  background: #1a1a1b;
  border-color: #343536;
}

.dark-mode .post-card:hover {
  border-color: #818384;
}

.light-mode .post-card {
  background: #ffffff;
  border-color: #ccc;
}

.light-mode .post-card:hover {
  border-color: #898989;
}

/* Post Flair */
.reddit-content .post-flair {
  display: inline-block;
  padding: 0.125rem 0.5rem;
  border-radius: 9999px;
  font-size: 12px;
  font-weight: 600;
  margin-right: 0.5rem;
  background: #ff4500;
  color: white;
}

/* Post Meta */
.reddit-content .post-meta {
  font-size: 12px;
  margin-top: 0.5rem;
}

.dark-mode .post-meta {
  color: #818384;
}

.light-mode .post-meta {
  color: #7c7c7c;
}

/* Post Votes */
.reddit-content .post-votes {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-weight: 600;
  color: #ff4500;
  font-size: 13px;
}

/* Sidebar */
.reddit-content .sidebar {
  margin-top: 1.5rem;
  padding: 1rem;
  border-radius: 8px;
  border: 1px solid;
}

.dark-mode .sidebar {
  background: #1a1a1b;
  border-color: #343536;
}

.light-mode .sidebar {
  background: #ffffff;
  border-color: #ccc;
}

/* Rule Items */
.reddit-content .rule-item {
  padding: 0.75rem 0;
  border-bottom: 1px solid;
  font-size: 13px;
}

.reddit-content .rule-item:last-child {
  border-bottom: none;
}

.dark-mode .rule-item {
  border-color: #343536;
}

.light-mode .rule-item {
  border-color: #edeff1;
}

/* Generic styling for generated content */
.reddit-content h1, .reddit-content h2, .reddit-content h3 {
  margin-bottom: 0.75rem;
}

.reddit-content h1 {
  font-size: 1.5rem;
  font-weight: 700;
}

.reddit-content h2 {
  font-size: 1.25rem;
  font-weight: 600;
}

.reddit-content h3 {
  font-size: 1rem;
  font-weight: 600;
}

.reddit-content p {
  margin-bottom: 0.5rem;
}

.reddit-content ul, .reddit-content ol {
  margin-left: 1.5rem;
  margin-bottom: 0.75rem;
}

.reddit-content strong {
  font-weight: 600;
}

.reddit-content a {
  color: #ff4500;
  text-decoration: none;
}

.reddit-content a:hover {
  text-decoration: underline;
}

/* Upvote/Downvote styling */
.reddit-content .upvote {
  color: #ff4500;
}

.reddit-content .downvote {
  color: #7193ff;
}

/* Pinned post indicator */
.reddit-content .pinned {
  border-left: 3px solid #46d160;
  padding-left: 0.75rem;
}

/* Responsive layout hints */
@media (min-width: 768px) {
  .reddit-content .layout-wrapper {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 1.5rem;
  }
}