/*
Theme Name: NewsLive
Description: A modern news website theme inspired by sachlive.com. Features breaking news, multiple categories, responsive design, and newsletter signup.
Author: NewsLive Team
Version: 1.0
License: GPL v2 or later
Text Domain: newslive
*/

/* Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f9fafb;
}

/* Header Styles */
.site-header {
  background: white;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  border-bottom: 1px solid #e5e7eb;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.site-logo {
  font-size: 1.5rem;
  font-weight: bold;
  color: #dc2626;
  text-decoration: none;
}

.main-navigation {
  display: none;
}

.main-navigation ul {
  display: flex;
  list-style: none;
  gap: 2rem;
}

.main-navigation a {
  color: #374151;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.875rem;
  padding: 0.5rem 0.75rem;
  transition: color 0.2s;
}

.main-navigation a:hover {
  color: #dc2626;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.search-btn, .user-btn, .mobile-menu-btn {
  background: none;
  border: none;
  padding: 0.5rem;
  cursor: pointer;
  border-radius: 0.375rem;
  transition: background-color 0.2s;
}

.search-btn:hover, .user-btn:hover, .mobile-menu-btn:hover {
  background-color: #f3f4f6;
}

.mobile-menu {
  display: none;
  border-top: 1px solid #e5e7eb;
  padding: 1rem;
}

.mobile-menu.active {
  display: block;
}

.mobile-menu ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.mobile-menu a {
  color: #374151;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.875rem;
  padding: 0.5rem 0.75rem;
}

/* Breaking News Ticker */
.breaking-news {
  background-color: #dc2626;
  color: white;
  padding: 0.5rem 0;
}

.breaking-news-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem;
  display: flex;
  align-items: center;
}

.breaking-label {
  background: white;
  color: #dc2626;
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
  font-size: 0.75rem;
  font-weight: bold;
  margin-right: 1rem;
  flex-shrink: 0;
}

.breaking-text {
  overflow: hidden;
  white-space: nowrap;
}

.breaking-text span {
  display: inline-block;
  animation: marquee 15s linear infinite;
}

@keyframes marquee {
  0% { transform: translateX(100%); }
  100% { transform: translateX(-100%); }
}

/* Main Content */
.site-main {
  max-width: 1280px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

/* News Cards */
.news-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  margin-bottom: 3rem;
}

.news-card {
  background: white;
  border-radius: 0.5rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  transition: all 0.2s;
}

.news-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.news-card.featured {
  grid-column: span 1;
}

.news-card-image {
  position: relative;
  width: 100%;
  height: 200px;
  overflow: hidden;
}

.news-card.featured .news-card-image {
  height: 250px;
}

.news-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.news-category {
  position: absolute;
  top: 0.5rem;
  left: 0.5rem;
  background: #dc2626;
  color: white;
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
  font-size: 0.75rem;
  font-weight: 600;
}

.news-card-content {
  padding: 1rem;
}

.news-card h3 {
  font-size: 1rem;
  font-weight: bold;
  color: #111827;
  margin-bottom: 0.5rem;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.news-card.featured h3 {
  font-size: 1.25rem;
}

.news-meta {
  display: flex;
  align-items: center;
  font-size: 0.875rem;
  color: #6b7280;
  margin-top: 0.5rem;
}

.news-meta span:not(:last-child)::after {
  content: "•";
  margin: 0 0.5rem;
}

/* Section Headers */
.section-header {
  font-size: 1.5rem;
  font-weight: bold;
  color: #111827;
  margin-bottom: 1.5rem;
  border-left: 4px solid #dc2626;
  padding-left: 1rem;
}

/* Newsletter Section */
.newsletter-section {
  background: #111827;
  color: white;
  padding: 3rem 0;
  text-align: center;
}

.newsletter-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem;
}

.newsletter-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.newsletter-section h2 {
  font-size: 1.5rem;
  font-weight: bold;
  margin-bottom: 0.5rem;
}

.newsletter-section p {
  color: #d1d5db;
  margin-bottom: 1.5rem;
}

.newsletter-form {
  max-width: 400px;
  margin: 0 auto;
  display: flex;
  gap: 0.5rem;
}

.newsletter-input {
  flex: 1;
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  border: none;
  color: #111827;
}

.newsletter-btn {
  background: #dc2626;
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.2s;
}

.newsletter-btn:hover {
  background: #b91c1c;
}

.newsletter-disclaimer {
  font-size: 0.75rem;
  color: #9ca3af;
  margin-top: 0.5rem;
}

.newsletter-disclaimer a {
  color: white;
  text-decoration: underline;
}

/* Footer */
.site-footer {
  background: #374151;
  color: white;
  padding: 2rem 0;
  text-align: center;
}

.footer-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem;
}

.footer-description {
  font-size: 0.875rem;
  color: #9ca3af;
  margin-bottom: 1rem;
}

.footer-links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1.5rem;
  font-size: 0.875rem;
}

.footer-links a {
  color: white;
  text-decoration: none;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: #fca5a5;
}

/* Responsive Design */
@media (min-width: 768px) {
  .main-navigation {
    display: block;
  }
  
  .mobile-menu-btn {
    display: none;
  }
  
  .news-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .news-card.featured {
    grid-column: span 2;
  }
  
  .newsletter-form {
    flex-direction: row;
  }
}

@media (max-width: 767px) {
  .main-navigation {
    display: none;
  }
  
  .newsletter-form {
    flex-direction: column;
  }
  
  .footer-links {
    flex-direction: column;
    gap: 0.5rem;
  }
}

