/*
Theme Name: TwolvesBlog
Theme URI: https://twolvesblog.com
Author: TwolvesBlog
Description: Minnesota Timberwolves fan coverage — dark mode, comic art showcase
Version: 2.0.0
License: GPL v2
Text Domain: twolvesblog
*/

/* === CSS Variables — Wolves Palette === */
:root {
  --primary: #0C2340;
  --primary-light: #122d4d;
  --secondary: #236192;
  --accent: #78BE20;
  --accent-dark: #5f9a14;
  --white: #ffffff;
  --gray-100: #0a1a2e;
  --gray-200: rgba(158,162,162,0.15);
  --gray-600: #9EA2A2;
  --gray-800: #e0e0e0;
  --font-heading: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;
  --font-body: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.3);
  --shadow-md: 0 4px 6px rgba(0,0,0,0.3);
  --shadow-lg: 0 10px 15px rgba(0,0,0,0.4);
  --radius: 8px;
}

/* === Reset & Base === */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--gray-800);
  background: #0a1a2e;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: var(--secondary);
}

/* === Header === */
.site-header {
  background: rgba(12,35,64,0.97);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow-md);
  border-bottom: 1px solid var(--gray-200);
}

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

.site-logo {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--white);
  text-transform: uppercase;
  letter-spacing: -0.5px;
}

.site-logo span {
  color: var(--accent);
}

/* === Navigation === */
.main-nav {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.main-nav ul {
  display: flex;
  list-style: none;
  gap: 1.5rem;
}

.main-nav a {
  color: rgba(255,255,255,0.85);
  font-weight: 500;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 0.5rem 0;
  position: relative;
}

.main-nav a:hover {
  color: var(--white);
}

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

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

/* === Hero Section === */
.hero-section {
  background: linear-gradient(135deg, var(--primary) 0%, #1a365d 100%);
  padding: 2rem 1rem;
  margin-bottom: 2rem;
}

.hero-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 1.5rem;
  align-items: stretch;
}

.hero-featured {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.hero-featured a {
  display: block;
}

.hero-featured img {
  width: 100%;
  height: 100%;
  min-height: 350px;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(0,0,0,0.85));
  padding: 2rem;
}

.hero-category {
  display: inline-block;
  background: var(--accent);
  color: var(--primary);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 0.2rem 0.6rem;
  border-radius: 3px;
  margin-bottom: 0.6rem;
}

.hero-title {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--white);
  line-height: 1.25;
  margin-bottom: 0.4rem;
}

.hero-title a {
  color: inherit;
}

.hero-meta {
  color: rgba(255,255,255,0.65);
  font-size: 0.8rem;
}

.hero-secondary {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.hero-card {
  background: rgba(255,255,255,0.06);
  backdrop-filter: blur(10px);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
  border: 1px solid rgba(255,255,255,0.08);
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  transition: background 0.2s;
}

.hero-card:hover {
  background: rgba(255,255,255,0.1);
}

.hero-card-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--white);
  line-height: 1.35;
}

.hero-card-title a {
  color: inherit;
}

.hero-card-title a:hover {
  color: var(--accent);
}

.hero-card .hero-meta {
  margin-top: 0.35rem;
  font-size: 0.75rem;
}

/* === Main Content === */
.main-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem 3rem;
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 2rem;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  padding-bottom: 0.6rem;
  border-bottom: 3px solid var(--accent);
}

.section-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--white);
  text-transform: uppercase;
  letter-spacing: -0.3px;
}

.view-all {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent);
}

/* === Article Cards === */
.article-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}

.article-card {
  background: var(--primary);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--gray-200);
  transition: transform 0.2s, box-shadow 0.2s;
}

.article-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

.article-image {
  position: relative;
  overflow: hidden;
}

.article-image img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  transition: transform 0.3s;
}

.article-card:hover .article-image img {
  transform: scale(1.05);
}

.article-category {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  background: var(--accent);
  color: var(--primary);
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 0.2rem 0.5rem;
  border-radius: 3px;
}

.article-content {
  padding: 1rem 1.25rem 1.25rem;
}

.article-title {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: 0.4rem;
  color: var(--white);
}

.article-title a {
  color: inherit;
}

.article-title a:hover {
  color: var(--accent);
}

.article-excerpt {
  font-size: 0.85rem;
  color: var(--gray-600);
  line-height: 1.5;
  margin-bottom: 0.75rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.article-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.75rem;
  color: var(--gray-600);
}

/* === No-Image Placeholder === */
.no-image-placeholder {
  width: 100%;
  height: 180px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.no-image-placeholder svg {
  width: 48px;
  height: 48px;
  opacity: 0.3;
}

/* === Sidebar === */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.widget {
  background: var(--primary);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--gray-200);
}

.widget-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--white);
  text-transform: uppercase;
  margin-bottom: 0.75rem;
  padding-bottom: 0.4rem;
  border-bottom: 2px solid var(--accent);
}

.widget-list {
  list-style: none;
}

.widget-list li {
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--gray-200);
}

.widget-list li:last-child {
  border-bottom: none;
}

.widget-list a {
  color: var(--gray-800);
  font-weight: 500;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.widget-list a:hover {
  color: var(--accent);
}

.widget-list .count,
.widget-list .post-count {
  color: var(--gray-600);
  font-size: 0.75rem;
  margin-left: auto;
}

/* === Pagination === */
.pagination {
  margin-top: 2rem;
  text-align: center;
}

.pagination .nav-links {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
}

.pagination a, .pagination span {
  padding: 0.5rem 1rem;
  border-radius: 4px;
  font-size: 0.85rem;
  font-weight: 500;
}

.pagination a {
  background: var(--primary);
  color: var(--gray-800);
  border: 1px solid var(--gray-200);
}

.pagination a:hover {
  background: var(--secondary);
  color: var(--white);
}

.pagination .current {
  background: var(--accent);
  color: var(--primary);
  font-weight: 700;
}

/* === Single Post === */
.single-post {
  background: var(--primary);
  border-radius: var(--radius);
  padding: 2rem;
  border: 1px solid var(--gray-200);
}

.single-post .breadcrumb {
  font-size: 0.8rem;
  margin-bottom: 1rem;
  color: var(--gray-600);
}

.single-post .breadcrumb a {
  color: var(--gray-600);
}

.single-post .breadcrumb a:hover {
  color: var(--accent);
}

.single-post .post-header h1 {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1.2;
  color: var(--white);
  margin-bottom: 0.75rem;
}

.single-post .post-header .article-meta {
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}

.single-post .featured-image {
  margin: 0 -2rem 2rem;
  border-radius: 0;
  overflow: hidden;
}

.single-post .featured-image img {
  width: 100%;
  height: auto;
}

.post-content {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--gray-800);
}

.post-content p {
  margin-bottom: 1.25rem;
}

.post-content h2, .post-content h3 {
  color: var(--white);
  margin: 2rem 0 1rem;
}

.post-content a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.post-content blockquote {
  border-left: 4px solid var(--accent);
  padding: 1rem 1.5rem;
  margin: 1.5rem 0;
  background: rgba(35,97,146,0.15);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-style: italic;
  color: var(--gray-800);
}

.post-content img {
  border-radius: var(--radius);
  margin: 1.5rem 0;
}

/* Twitter embeds */
.post-content .twitter-tweet {
  margin: 1.5rem auto !important;
}

.post-footer {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--gray-200);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.85rem;
  color: var(--gray-600);
}

.post-footer a {
  color: var(--accent);
}

.share-links a {
  display: inline-block;
  padding: 0.4rem 0.8rem;
  background: var(--secondary);
  color: var(--white) !important;
  border-radius: 4px;
  font-size: 0.8rem;
  font-weight: 500;
  margin-left: 0.4rem;
}

.share-links a:hover {
  background: var(--accent);
  color: var(--primary) !important;
}

/* === Footer === */
.site-footer {
  background: var(--primary);
  color: rgba(255,255,255,0.7);
  padding: 2.5rem 1rem 1rem;
  margin-top: 2rem;
  border-top: 1px solid var(--gray-200);
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-widget h4 {
  color: var(--white);
  font-size: 0.9rem;
  font-weight: 600;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

.footer-widget ul {
  list-style: none;
}

.footer-widget li {
  margin-bottom: 0.4rem;
}

.footer-widget a {
  color: rgba(255,255,255,0.6);
  font-size: 0.85rem;
}

.footer-widget a:hover {
  color: var(--accent);
}

.footer-bottom {
  max-width: 1200px;
  margin: 0 auto;
  padding-top: 1rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  text-align: center;
  font-size: 0.8rem;
  color: rgba(255,255,255,0.4);
}

/* === Mobile Menu === */
.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--white);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.25rem;
}

/* === 404 === */
.not-found {
  text-align: center;
  padding: 4rem 1rem;
}

.not-found h1 {
  font-size: 4rem;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.not-found p {
  color: var(--gray-600);
  font-size: 1.1rem;
}

/* === Responsive === */
@media (max-width: 1024px) {
  .hero-container {
    grid-template-columns: 1fr;
  }

  .hero-featured img {
    min-height: 280px;
  }

  .hero-secondary {
    flex-direction: row;
    overflow-x: auto;
  }

  .hero-card {
    min-width: 200px;
  }

  .main-container {
    grid-template-columns: 1fr;
  }

  .sidebar {
    order: 2;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
  }
}

@media (max-width: 768px) {
  .mobile-menu-toggle {
    display: block;
  }

  .main-nav ul {
    display: none;
    position: absolute;
    top: 60px;
    left: 0;
    right: 0;
    background: var(--primary);
    flex-direction: column;
    padding: 1rem;
    gap: 0;
    border-bottom: 1px solid var(--gray-200);
  }

  .main-nav ul.active {
    display: flex;
  }

  .main-nav li {
    border-bottom: 1px solid rgba(255,255,255,0.05);
  }

  .main-nav a {
    display: block;
    padding: 0.75rem 0;
  }

  .article-grid {
    grid-template-columns: 1fr;
  }

  .footer-container {
    grid-template-columns: 1fr;
  }

  .sidebar {
    grid-template-columns: 1fr;
  }

  .single-post {
    padding: 1.25rem;
  }

  .single-post .featured-image {
    margin: 0 -1.25rem 1.5rem;
  }

  .single-post .post-header h1 {
    font-size: 1.5rem;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 1.25rem;
  }

  .hero-secondary {
    flex-direction: column;
  }

  .hero-card {
    min-width: auto;
  }
}
