/**
 * Theme Name: Best100Apps
 * Theme URI: https://best100apps.com
 * Author: Best100Apps
 * Author URI: https://best100apps.com
 * Description: A modern, AI-focused news theme designed for tech publications. Features advertising spaces, responsive design, and optimized for AI tools content.
 * Version: 1.0.0
 * License: GPL v2 or later
 * License URI: https://www.gnu.org/licenses/gpl-2.0.html
 * Text Domain: best100apps
 * Domain Path: /languages
 * Tags: news, ai, tech, responsive, advertising, modern
 */

/* ================================
   CSS VARIABLES & ROOT
   ================================ */
:root {
  /* Brand Colors - Modern AI Tech Palette */
  --primary-color: #6366f1;
  --primary-dark: #4f46e5;
  --primary-light: #818cf8;
  --secondary-color: #06b6d4;
  --accent-color: #f59e0b;
  --success-color: #10b981;
  --warning-color: #f59e0b;
  --error-color: #ef4444;
  
  /* Neutral Colors */
  --dark-bg: #0f172a;
  --dark-card: #1e293b;
  --dark-border: #334155;
  --light-bg: #f8fafc;
  --light-card: #ffffff;
  --light-border: #e2e8f0;
  
  /* Text Colors */
  --text-primary: #0f172a;
  --text-secondary: #64748b;
  --text-muted: #94a3b8;
  --text-light: #f1f5f9;
  
  /* AI Gradient Accent */
  --ai-gradient: linear-gradient(135deg, #6366f1 0%, #06b6d4 50%, #10b981 100%);
  --ai-glow: 0 0 20px rgba(99, 102, 241, 0.3);
  
  /* Spacing */
  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 1.5rem;
  --space-lg: 2rem;
  --space-xl: 3rem;
  --space-xxl: 4rem;
  
  /* Typography */
  --font-heading: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
  
  /* Font Sizes */
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.25rem;
  --text-2xl: 1.5rem;
  --text-3xl: 1.875rem;
  --text-4xl: 2.25rem;
  --text-5xl: 3rem;
  
  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  --shadow-glow: 0 0 30px rgba(99, 102, 241, 0.2);
  
  /* Border Radius */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  
  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-normal: 300ms ease;
  --transition-slow: 500ms ease;
  
  /* Ad Space Heights */
  --ad-leaderboard: 90px;
  --ad-medium-rect: 250px;
  --ad-half-page: 600px;
  --ad-mobile-banner: 50px;
  
  /* Container */
  --container-max: 1400px;
  --content-max: 930px;
}

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

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

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--light-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--primary-dark);
}

/* ================================
   TYPOGRAPHY
   ================================ */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: var(--space-sm);
  color: var(--text-primary);
}

h1 { font-size: var(--text-5xl); }
h2 { font-size: var(--text-4xl); }
h3 { font-size: var(--text-3xl); }
h4 { font-size: var(--text-2xl); }
h5 { font-size: var(--text-xl); }
h6 { font-size: var(--text-lg); }

p {
  margin-bottom: var(--space-sm);
}

/* ================================
   LAYOUT - CONTAINER
   ================================ */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--space-md);
}

.content-area {
  max-width: var(--content-max);
  margin: 0 auto;
}

/* ================================
   HEADER & NAVIGATION
   ================================ */
.site-header {
  background: var(--light-card);
  border-bottom: 1px solid var(--light-border);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow-sm);
}

.header-top {
  background: var(--dark-bg);
  color: var(--text-light);
  padding: var(--space-xs) 0;
  font-size: var(--text-sm);
}

.header-top-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header-breaking-news {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.breaking-label {
  background: var(--error-color);
  color: white;
  padding: 0.25rem 0.75rem;
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  border-radius: var(--radius-sm);
  animation: pulse 2s infinite;
}

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

.header-main {
  padding: var(--space-md) 0;
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.site-branding {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.site-logo {
  font-size: var(--text-2xl);
  font-weight: 800;
  background: var(--ai-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.site-description {
  font-size: var(--text-sm);
  color: var(--text-secondary);
}

/* AI Badge */
.ai-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--ai-gradient);
  color: white;
  padding: 0.5rem 1rem;
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  box-shadow: var(--ai-glow);
}

.ai-badge svg {
  width: 16px;
  height: 16px;
}

/* Main Navigation */
.main-navigation {
  background: var(--light-card);
  border-top: 1px solid var(--light-border);
}

.nav-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: var(--space-lg);
}

.nav-menu a {
  display: block;
  padding: var(--space-sm) 0;
  font-weight: 600;
  color: var(--text-primary);
  position: relative;
}

.nav-menu a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--ai-gradient);
  transition: width var(--transition-normal);
}

.nav-menu a:hover::after,
.nav-menu .current-menu-item a::after {
  width: 100%;
}

/* Search Toggle */
.search-toggle {
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--space-sm);
  color: var(--text-primary);
  transition: color var(--transition-fast);
}

.search-toggle:hover {
  color: var(--primary-color);
}

/* Mobile Menu Toggle */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--space-sm);
}

.menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  margin: 5px 0;
  transition: var(--transition-fast);
}

/* ================================
   ADVERTISING SPACES
   ================================ */
.ad-space {
  background: var(--light-bg);
  border: 2px dashed var(--light-border);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: var(--text-sm);
  color: var(--text-muted);
  transition: all var(--transition-fast);
  position: relative;
  overflow: hidden;
}

.ad-space::before {
  content: 'Advertisement';
  position: absolute;
  top: 0.25rem;
  left: 50%;
  transform: translateX(-50%);
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  opacity: 0.5;
}

.ad-space:hover {
  border-color: var(--primary-light);
  background: rgba(99, 102, 241, 0.05);
}

.ad-leaderboard {
  width: 100%;
  height: var(--ad-leaderboard);
  max-width: 728px;
  margin: var(--space-md) auto;
}

.ad-medium-rectangle {
  width: 300px;
  height: var(--ad-medium-rect);
}

.ad-half-page {
  width: 300px;
  height: var(--ad-half-page);
}

.ad-sticky-sidebar {
  position: sticky;
  top: 100px;
}

.ad-in-content {
  width: 100%;
  height: auto;
  min-height: 250px;
  margin: var(--space-lg) 0;
}

.ad-header {
  background: var(--dark-bg);
  padding: var(--space-sm) 0;
}

.ad-header .ad-space {
  background: transparent;
  border-color: var(--dark-border);
  color: var(--text-muted);
}

/* ================================
   HERO SECTION - AI FEATURED
   ================================ */
.hero-section {
  padding: var(--space-xxl) 0;
  background: linear-gradient(135deg, var(--dark-bg) 0%, var(--dark-card) 100%);
  color: var(--text-light);
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: 
    radial-gradient(circle at 20% 80%, rgba(99, 102, 241, 0.15) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(6, 182, 212, 0.15) 0%, transparent 50%);
  pointer-events: none;
}

.hero-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: var(--space-xl);
  position: relative;
  z-index: 1;
}

.hero-featured {
  position: relative;
}

.hero-featured .post-card {
  background: var(--dark-card);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--dark-border);
}

.hero-featured .post-thumbnail {
  aspect-ratio: 16/9;
  overflow: hidden;
}

.hero-featured .post-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.hero-featured .post-card:hover .post-thumbnail img {
  transform: scale(1.05);
}

.hero-featured .post-content {
  padding: var(--space-lg);
}

.hero-featured .post-title {
  font-size: var(--text-3xl);
  color: var(--text-light);
  margin-bottom: var(--space-sm);
}

.hero-featured .post-excerpt {
  color: var(--text-muted);
  font-size: var(--text-lg);
  margin-bottom: var(--space-md);
}

.hero-side {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.hero-side .post-card {
  background: var(--dark-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--dark-border);
  display: flex;
  flex-direction: column;
}

.hero-side .post-thumbnail {
  aspect-ratio: 16/9;
}

.hero-side .post-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-side .post-content {
  padding: var(--space-md);
}

.hero-side .post-title {
  font-size: var(--text-lg);
  color: var(--text-light);
  margin-bottom: var(--space-xs);
}

/* ================================
   AI TOOLS SHOWCASE SECTION
   ================================ */
.ai-tools-section {
  padding: var(--space-xxl) 0;
  background: var(--light-bg);
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-xl);
}

.section-title {
  font-size: var(--text-3xl);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.section-title svg {
  width: 32px;
  height: 32px;
  color: var(--primary-color);
}

.view-all-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  color: var(--primary-color);
}

.ai-tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: var(--space-lg);
}

.ai-tool-card {
  background: var(--light-card);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  border: 1px solid var(--light-border);
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.ai-tool-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--ai-gradient);
  transform: scaleX(0);
  transition: transform var(--transition-normal);
}

.ai-tool-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary-light);
}

.ai-tool-card:hover::before {
  transform: scaleX(1);
}

.ai-tool-icon {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-lg);
  background: var(--ai-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-md);
  box-shadow: var(--ai-glow);
}

.ai-tool-icon svg {
  width: 32px;
  height: 32px;
  color: white;
}

.ai-tool-name {
  font-size: var(--text-xl);
  font-weight: 700;
  margin-bottom: var(--space-xs);
}

.ai-tool-category {
  display: inline-block;
  background: rgba(99, 102, 241, 0.1);
  color: var(--primary-color);
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
  margin-bottom: var(--space-sm);
}

.ai-tool-description {
  color: var(--text-secondary);
  font-size: var(--text-sm);
  margin-bottom: var(--space-md);
  line-height: 1.6;
}

.ai-tool-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: var(--space-md);
  border-top: 1px solid var(--light-border);
}

.ai-tool-rating {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  color: var(--accent-color);
}

.ai-tool-link {
  font-weight: 600;
  font-size: var(--text-sm);
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

/* ================================
   POST CARDS & LISTS
   ================================ */
.posts-section {
  padding: var(--space-xxl) 0;
}

.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: var(--space-xl);
}

.post-card {
  background: var(--light-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--light-border);
  transition: all var(--transition-normal);
}

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

.post-thumbnail {
  aspect-ratio: 16/10;
  overflow: hidden;
  background: var(--light-border);
}

.post-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.post-card:hover .post-thumbnail img {
  transform: scale(1.05);
}

.post-content {
  padding: var(--space-lg);
}

.post-category {
  display: inline-block;
  background: var(--ai-gradient);
  color: white;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-sm);
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: var(--space-sm);
}

.post-title {
  font-size: var(--text-xl);
  margin-bottom: var(--space-sm);
  line-height: 1.3;
}

.post-title a {
  color: var(--text-primary);
}

.post-title a:hover {
  color: var(--primary-color);
}

.post-meta {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  font-size: var(--text-sm);
  color: var(--text-secondary);
}

.post-meta span {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.post-excerpt {
  color: var(--text-secondary);
  margin-top: var(--space-sm);
  line-height: 1.6;
}

/* ================================
   SIDEBAR
   ================================ */
.site-content {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: var(--space-xl);
  padding: var(--space-xl) 0;
}

.sidebar {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

.sidebar-widget {
  background: var(--light-card);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  border: 1px solid var(--light-border);
}

.widget-title {
  font-size: var(--text-lg);
  margin-bottom: var(--space-md);
  padding-bottom: var(--space-sm);
  border-bottom: 2px solid var(--ai-gradient);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.widget-content {
  font-size: var(--text-sm);
}

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

.widget-content li {
  padding: var(--space-sm) 0;
  border-bottom: 1px solid var(--light-border);
}

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

.widget-content a {
  color: var(--text-primary);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.widget-content a:hover {
  color: var(--primary-color);
}

.trending-post {
  display: flex;
  gap: var(--space-sm);
  padding: var(--space-sm) 0;
  border-bottom: 1px solid var(--light-border);
}

.trending-post:last-child {
  border-bottom: none;
}

.trending-number {
  font-size: var(--text-2xl);
  font-weight: 800;
  color: var(--primary-light);
  line-height: 1;
  min-width: 2rem;
}

.trending-content h4 {
  font-size: var(--text-sm);
  margin-bottom: 0.25rem;
  line-height: 1.4;
}

.trending-content a {
  color: var(--text-primary);
}

.trending-content .post-date {
  font-size: var(--text-xs);
  color: var(--text-muted);
}

/* ================================
   NEWSLETTER SECTION
   ================================ */
.newsletter-section {
  background: var(--ai-gradient);
  padding: var(--space-xxl) 0;
  color: white;
  position: relative;
  overflow: hidden;
}

.newsletter-section::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  right: -50%;
  bottom: -50%;
  background: radial-gradient(circle, rgba(255,255,255,0.1) 1px, transparent 1px);
  background-size: 20px 20px;
  animation: grain 8s steps(10) infinite;
  opacity: 0.3;
}

@keyframes grain {
  0%, 100% { transform: translate(0, 0); }
  10% { transform: translate(-2%, -2%); }
  20% { transform: translate(2%, 2%); }
  30% { transform: translate(-1%, 1%); }
  40% { transform: translate(1%, -1%); }
  50% { transform: translate(-2%, 2%); }
  60% { transform: translate(2%, -2%); }
  70% { transform: translate(-1%, -1%); }
  80% { transform: translate(1%, 1%); }
  90% { transform: translate(-2%, -1%); }
}

.newsletter-content {
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.newsletter-title {
  font-size: var(--text-3xl);
  margin-bottom: var(--space-sm);
}

.newsletter-description {
  font-size: var(--text-lg);
  opacity: 0.9;
  margin-bottom: var(--space-lg);
}

.newsletter-form {
  display: flex;
  gap: var(--space-sm);
  max-width: 500px;
  margin: 0 auto;
}

.newsletter-form input[type="email"] {
  flex: 1;
  padding: var(--space-md);
  border: none;
  border-radius: var(--radius-md);
  font-size: var(--text-base);
  outline: none;
}

.newsletter-form button {
  padding: var(--space-md) var(--space-lg);
  background: var(--dark-bg);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.newsletter-form button:hover {
  background: var(--text-primary);
  transform: translateY(-2px);
}

/* ================================
   FOOTER
   ================================ */
.site-footer {
  background: var(--dark-bg);
  color: var(--text-light);
  padding-top: var(--space-xxl);
}

.footer-widgets {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-xl);
  padding-bottom: var(--space-xl);
  border-bottom: 1px solid var(--dark-border);
}

.footer-widget-title {
  font-size: var(--text-lg);
  color: white;
  margin-bottom: var(--space-md);
}

.footer-widget-content {
  font-size: var(--text-sm);
  color: var(--text-muted);
}

.footer-widget-content a {
  color: var(--text-muted);
}

.footer-widget-content a:hover {
  color: white;
}

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

.footer-widget-content li {
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--dark-border);
}

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

.footer-bottom {
  padding: var(--space-md) 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: var(--text-sm);
  color: var(--text-muted);
}

.footer-social {
  display: flex;
  gap: var(--space-sm);
}

.social-link {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: var(--dark-card);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: all var(--transition-fast);
}

.social-link:hover {
  background: var(--primary-color);
  color: white;
  transform: translateY(-2px);
}

/* ================================
   SINGLE POST
   ================================ */
.single-post .site-content {
  grid-template-columns: 1fr 340px;
}

.article-header {
  margin-bottom: var(--space-xl);
}

.article-category {
  display: inline-block;
  background: var(--ai-gradient);
  color: white;
  padding: 0.5rem 1rem;
  border-radius: var(--radius-sm);
  font-size: var(--text-sm);
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: var(--space-md);
}

.article-title {
  font-size: var(--text-4xl);
  line-height: 1.2;
  margin-bottom: var(--space-md);
}

.article-meta {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
  color: var(--text-secondary);
  font-size: var(--text-sm);
}

.article-featured-image {
  width: 100%;
  aspect-ratio: 21/9;
  border-radius: var(--radius-xl);
  overflow: hidden;
  margin-bottom: var(--space-xl);
}

.article-featured-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.article-content {
  font-size: var(--text-lg);
  line-height: 1.8;
  color: var(--text-primary);
}

.article-content h2 {
  font-size: var(--text-2xl);
  margin-top: var(--space-xl);
  margin-bottom: var(--space-md);
}

.article-content h3 {
  font-size: var(--text-xl);
  margin-top: var(--space-lg);
  margin-bottom: var(--space-sm);
}

.article-content p {
  margin-bottom: var(--space-md);
}

.article-content img {
  border-radius: var(--radius-lg);
  margin: var(--space-lg) 0;
}

.article-content blockquote {
  border-left: 4px solid var(--primary-color);
  padding-left: var(--space-md);
  margin: var(--space-lg) 0;
  font-style: italic;
  color: var(--text-secondary);
}

.article-content a {
  color: var(--primary-color);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

/* ================================
   TAGS & SHARE
   ================================ */
.article-tags {
  margin-top: var(--space-xl);
  padding-top: var(--space-lg);
  border-top: 1px solid var(--light-border);
}

.tags-list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
}

.tag-link {
  display: inline-block;
  padding: 0.5rem 1rem;
  background: var(--light-bg);
  border: 1px solid var(--light-border);
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
  transition: all var(--transition-fast);
}

.tag-link:hover {
  background: var(--primary-color);
  border-color: var(--primary-color);
  color: white;
}

.share-section {
  margin-top: var(--space-lg);
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.share-title {
  font-weight: 600;
  font-size: var(--text-sm);
}

.share-buttons {
  display: flex;
  gap: var(--space-xs);
}

.share-button {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: var(--light-bg);
  border: 1px solid var(--light-border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  transition: all var(--transition-fast);
}

.share-button:hover {
  background: var(--primary-color);
  border-color: var(--primary-color);
  color: white;
  transform: translateY(-2px);
}

/* ================================
   RELATED POSTS
   ================================ */
.related-posts {
  margin-top: var(--space-xxl);
  padding-top: var(--space-xl);
  border-top: 1px solid var(--light-border);
}

.related-posts-title {
  font-size: var(--text-2xl);
  margin-bottom: var(--space-lg);
}

.related-posts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-lg);
}

/* ================================
   PAGINATION
   ================================ */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: var(--space-xs);
  margin-top: var(--space-xl);
}

.pagination a,
.pagination .current {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 var(--space-sm);
  border-radius: var(--radius-md);
  font-weight: 600;
  transition: all var(--transition-fast);
}

.pagination a {
  background: var(--light-bg);
  color: var(--text-primary);
  border: 1px solid var(--light-border);
}

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

.pagination .current {
  background: var(--ai-gradient);
  color: white;
}

/* ================================
   BREADCRUMBS
   ================================ */
.breadcrumbs {
  padding: var(--space-sm) 0;
  font-size: var(--text-sm);
  color: var(--text-secondary);
  border-bottom: 1px solid var(--light-border);
  margin-bottom: var(--space-lg);
}

.breadcrumbs a {
  color: var(--text-secondary);
}

.breadcrumbs a:hover {
  color: var(--primary-color);
}

.breadcrumbs .separator {
  margin: 0 0.5rem;
  opacity: 0.5;
}

/* ================================
   AUTHOR BOX
   ================================ */
.author-box {
  background: var(--light-bg);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  margin-top: var(--space-xl);
  display: flex;
  gap: var(--space-lg);
  align-items: flex-start;
}

.author-avatar {
  width: 100px;
  height: 100px;
  border-radius: var(--radius-full);
  overflow: hidden;
  flex-shrink: 0;
}

.author-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.author-info h3 {
  font-size: var(--text-xl);
  margin-bottom: var(--space-xs);
}

.author-bio {
  color: var(--text-secondary);
  font-size: var(--text-sm);
  line-height: 1.6;
}

/* ================================
   READING PROGRESS
   ================================ */
.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: var(--ai-gradient);
  z-index: 9999;
  transition: width 0.1s ease;
}

/* ================================
   AI TOOLS ARCHIVE
   ================================ */
.ai-tools-archive .archive-header {
  text-align: center;
  padding: var(--space-xxl) 0;
  background: linear-gradient(135deg, var(--dark-bg) 0%, var(--dark-card) 100%);
  color: var(--text-light);
  margin-bottom: var(--space-xl);
  border-radius: var(--radius-xl);
}

.ai-tools-archive .archive-title {
  color: white;
  font-size: var(--text-4xl);
  margin-bottom: var(--space-sm);
}

.ai-tools-archive .archive-description {
  font-size: var(--text-lg);
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto;
}

.ai-categories-filter {
  margin-bottom: var(--space-xl);
}

.filter-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  justify-content: center;
}

.filter-btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  background: var(--light-bg);
  border: 1px solid var(--light-border);
  border-radius: var(--radius-full);
  font-weight: 600;
  transition: all var(--transition-fast);
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--ai-gradient);
  border-color: transparent;
  color: white;
}

.ai-tools-grid-full {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
  gap: var(--space-xl);
  margin-bottom: var(--space-xl);
}

.ai-tool-card-detailed {
  background: var(--light-card);
  border-radius: var(--radius-xl);
  border: 1px solid var(--light-border);
  overflow: hidden;
  transition: all var(--transition-normal);
}

.ai-tool-card-detailed:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
  border-color: var(--primary-light);
}

.ai-tool-header {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-lg);
  border-bottom: 1px solid var(--light-border);
}

.ai-tool-icon-large {
  width: 80px;
  height: 80px;
  border-radius: var(--radius-lg);
  background: var(--ai-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
}

.ai-tool-icon-large img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ai-tool-icon-large svg {
  width: 40px;
  height: 40px;
  color: white;
}

.ai-tool-header-info {
  flex: 1;
}

.ai-tool-name-large {
  font-size: var(--text-xl);
  margin-bottom: var(--space-xs);
}

.ai-tool-name-large a {
  color: var(--text-primary);
}

.ai-tool-category-tag {
  display: inline-block;
  background: rgba(99, 102, 241, 0.1);
  color: var(--primary-color);
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-sm);
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
}

.ai-tool-body {
  padding: var(--space-lg);
}

.ai-tool-description-large {
  color: var(--text-secondary);
  margin-bottom: var(--space-md);
  line-height: 1.6;
}

.ai-tool-features {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
}

.feature-tag {
  display: inline-block;
  padding: 0.5rem 1rem;
  background: var(--light-bg);
  border: 1px solid var(--light-border);
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
  color: var(--text-secondary);
}

.ai-tool-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-lg);
  border-top: 1px solid var(--light-border);
  background: var(--light-bg);
}

.ai-tool-stats {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.ai-tool-rating-large {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-weight: 700;
  color: var(--accent-color);
}

.ai-tool-pricing {
  font-size: var(--text-sm);
  color: var(--text-secondary);
  font-weight: 600;
}

.ai-tool-actions {
  display: flex;
  gap: var(--space-sm);
}

.btn-review,
.btn-visit {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: var(--text-sm);
  transition: all var(--transition-fast);
}

.btn-review {
  background: var(--light-card);
  border: 1px solid var(--light-border);
  color: var(--text-primary);
}

.btn-review:hover {
  background: var(--primary-color);
  border-color: var(--primary-color);
  color: white;
}

.btn-visit {
  background: var(--ai-gradient);
  color: white;
  border: none;
}

.btn-visit:hover {
  transform: translateY(-2px);
  box-shadow: var(--ai-glow);
}

/* ================================
   AUTHOR PAGE
   ================================ */
.author-profile-header {
  padding: var(--space-xxl) 0;
  background: linear-gradient(135deg, var(--dark-bg) 0%, var(--dark-card) 100%);
  margin-bottom: var(--space-xl);
}

.author-profile-card {
  display: flex;
  gap: var(--space-xl);
  align-items: flex-start;
  max-width: 800px;
  margin: 0 auto;
}

.author-avatar-large {
  width: 150px;
  height: 150px;
  border-radius: var(--radius-full);
  overflow: hidden;
  border: 4px solid var(--primary-color);
  flex-shrink: 0;
}

.author-avatar-large img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.author-profile-info {
  color: var(--text-light);
  flex: 1;
}

.author-name {
  font-size: var(--text-3xl);
  color: white;
  margin-bottom: var(--space-sm);
}

.author-website {
  display: inline-block;
  color: var(--primary-light);
  margin-bottom: var(--space-md);
  font-size: var(--text-sm);
}

.author-website:hover {
  color: white;
}

.author-bio-full {
  font-size: var(--text-base);
  line-height: 1.8;
  color: var(--text-muted);
  margin-bottom: var(--space-md);
}

.author-stats {
  display: flex;
  gap: var(--space-lg);
}

.author-stat {
  font-size: var(--text-sm);
  color: var(--text-muted);
}

.author-stat strong {
  color: white;
  font-size: var(--text-xl);
  display: block;
}

.author-posts-section {
  padding-bottom: var(--space-xxl);
}

.author-posts-section .section-title {
  margin-bottom: var(--space-xl);
}

@media (max-width: 768px) {
  .ai-tools-grid-full {
    grid-template-columns: 1fr;
  }
  
  .ai-tool-header {
    flex-direction: column;
    text-align: center;
  }
  
  .ai-tool-footer {
    flex-direction: column;
    gap: var(--space-md);
    text-align: center;
  }
  
  .ai-tool-actions {
    width: 100%;
    justify-content: center;
  }
  
  .author-profile-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  
  .author-stats {
    justify-content: center;
  }
  
  .filter-buttons {
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: var(--space-sm);
  }
}

/* ================================
   DARK MODE SUPPORT
   ================================ */
@media (prefers-color-scheme: dark) {
  :root {
    --light-bg: #0f172a;
    --light-card: #1e293b;
    --light-border: #334155;
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
  }
  
  .ad-space {
    background: var(--dark-card);
    border-color: var(--dark-border);
  }
}

/* ================================
   RESPONSIVE DESIGN
   ================================ */
@media (max-width: 1200px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }
  
  .hero-side {
    flex-direction: row;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
  }
  
  .hero-side .post-card {
    flex: 0 0 300px;
    scroll-snap-align: start;
  }
  
  .site-content {
    grid-template-columns: 1fr;
  }
  
  .sidebar {
    order: 2;
  }
}

@media (max-width: 992px) {
  .ai-tools-grid {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  }
  
  .footer-widgets {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .single-post .site-content {
    grid-template-columns: 1fr;
  }
  
  .related-posts-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  :root {
    --text-5xl: 2rem;
    --text-4xl: 1.75rem;
    --text-3xl: 1.5rem;
  }
  
  .header-top {
    display: none;
  }
  
  .menu-toggle {
    display: block;
  }
  
  .main-navigation .nav-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--light-card);
    flex-direction: column;
    padding: var(--space-md);
    border-top: 1px solid var(--light-border);
    box-shadow: var(--shadow-lg);
  }
  
  .main-navigation .nav-menu.active {
    display: flex;
  }
  
  .nav-menu a::after {
    display: none;
  }
  
  .hero-featured .post-title {
    font-size: var(--text-xl);
  }
  
  .newsletter-form {
    flex-direction: column;
  }
  
  .footer-widgets {
    grid-template-columns: 1fr;
  }
  
  .footer-bottom {
    flex-direction: column;
    gap: var(--space-md);
    text-align: center;
  }
  
  .related-posts-grid {
    grid-template-columns: 1fr;
  }
  
  .author-box {
    flex-direction: column;
    text-align: center;
  }
  
  .author-avatar {
    margin: 0 auto;
  }
}

@media (max-width: 480px) {
  .ai-tools-grid,
  .posts-grid {
    grid-template-columns: 1fr;
  }
  
  .hero-side .post-card {
    flex: 0 0 260px;
  }
  
  .ad-medium-rectangle,
  .ad-half-page {
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
  }
}

/* ================================
   UTILITY CLASSES
   ================================ */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.hidden { display: none; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* Loading Skeleton */
.skeleton {
  background: linear-gradient(90deg, var(--light-border) 25%, var(--light-bg) 50%, var(--light-border) 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
  border-radius: var(--radius-md);
}

@keyframes skeleton-loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* Fade In Animation */
.fade-in {
  animation: fadeIn 0.5s ease-in;
}

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

/* Smooth Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--light-bg);
}

::-webkit-scrollbar-thumb {
  background: var(--light-border);
  border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}
