/*
Theme Name: InfoChef Pro
Description: Advanced bilingual business theme for InfoChef
Version: 2.0.0
Author: Snow
License: GPL-2.0
Text Domain: infochef-pro
*/

/* Modern Design System */
:root {
  --bg: #ffffff;
  --bg-alt: #f8fafc;
  --surface: #ffffff;
  --border: #e2e8f0;
  --muted: #64748b;
  --text: #0f172a;
  --text-secondary: #334155;
  --primary: #3b82f6;
  --primary-dark: #2563eb;
  --primary-light: #dbeafe;
  --accent: #f59e0b;
  --gradient-start: #3b82f6;
  --gradient-end: #8b5cf6;
  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 16px;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  --max-w: 1200px;
  --space: 1rem;
  --transition: 200ms ease;
}

/* Reset & Base */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', 'SF Pro Display', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
a { color: var(--primary); text-decoration: none; font-weight: 500; transition: color var(--transition); }
a:hover { color: var(--primary-dark); }
img { max-width: 100%; height: auto; display: block; border-radius: var(--radius-sm); }
ul, ol { padding-left: 1.5rem; }
li { margin: 0.5rem 0; }

/* Container */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 var(--space); }
.container-narrow { max-width: 840px; margin: 0 auto; padding: 0 var(--space); }

/* Typography */
h1, h2, h3, h4, h5, h6 {
  color: var(--text);
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.025em;
  margin-bottom: 1rem;
}
h1 { font-size: clamp(2rem, 5vw, 3rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.1rem; }

/* Hero Section */
.hero {
  background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
  color: white;
  padding: 5rem 0;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="50" cy="50" r="1" fill="rgba(255,255,255,0.15)"/></svg>');
  opacity: 0.6;
  background-size: 50px 50px;
}
.hero-content { position: relative; z-index: 1; }
.hero h1 { color: white; margin-bottom: 1.5rem; font-size: clamp(2.25rem, 5vw, 3.5rem); }
.hero p { font-size: 1.25rem; opacity: 0.95; margin-bottom: 2rem; max-width: 600px; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 1rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all var(--transition);
  white-space: nowrap;
}
.btn-primary {
  background: white;
  color: var(--primary-dark);
  border-color: white;
}
.btn-primary:hover {
  background: var(--primary-light);
  color: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}
.btn-secondary {
  background: transparent;
  color: white;
  border-color: rgba(255, 255, 255, 0.5);
}
.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: white;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid var(--border);
  transition: all var(--transition);
}
.site-header.scrolled { box-shadow: var(--shadow); }
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--space);
}
.brand {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, var(--primary), var(--gradient-end));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.brand:hover { color: var(--primary); }
.primary-menu a {
  display: inline-flex;
  align-items: center;
  padding: 0.5rem 1rem;
  border-radius: var(--radius-sm);
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--text-secondary);
  transition: all var(--transition);
}
.primary-menu a:hover {
  background: var(--bg-alt);
  color: var(--primary);
}
.menu-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.5rem;
  font-size: 1.25rem;
  cursor: pointer;
  color: var(--text);
  transition: all var(--transition);
}
.menu-toggle:hover { background: var(--bg-alt); }

@media (max-width: 768px) {
  .primary-menu {
    display: none;
    position: absolute;
    top: 72px;
    left: var(--space);
    right: var(--space);
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1rem;
    box-shadow: var(--shadow-xl);
  }
  .primary-menu.open { display: block; }
  .primary-menu a { display: block; padding: 0.75rem; margin: 0.25rem 0; }
  .menu-toggle { display: inline-flex; }
}

/* Cards */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
}
.card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
  border-color: var(--primary-light);
}
.card h2, .card h3 { margin: 0.75rem 0 0.5rem; }
.card p { color: var(--text-secondary); margin: 0.5rem 0; }
.card .btn { margin-top: 0.75rem; }

/* Grid */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}

/* Posts */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2rem;
  margin: 2rem 0;
}
.post-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
}
.post-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
}
.post-card-image {
  height: 200px;
  background: linear-gradient(135deg, var(--primary-light), #f1f5f9);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  color: var(--primary);
}
.post-card-content { padding: 1.5rem; flex: 1; display: flex; flex-direction: column; }
.post-card h2 {
  font-size: 1.25rem;
  margin: 0.5rem 0;
}
.post-card h2 a { color: var(--text); }
.post-card h2 a:hover { color: var(--primary); }
.post-meta {
  color: var(--muted);
  font-size: 0.875rem;
  margin: 0.5rem 0;
  display: flex;
  gap: 1rem;
}
.post-excerpt { color: var(--text-secondary); font-size: 0.95rem; margin: 0.75rem 0; flex: 1; }
.read-more {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  margin-top: auto;
  font-weight: 600;
  color: var(--primary);
  padding: 0.5rem 0;
}
.read-more:hover { gap: 0.5rem; }

/* Page Header */
.page-header {
  padding: 3rem 0 2rem;
  background: var(--bg-alt);
  border-bottom: 1px solid var(--border);
}
.page-header h1 { margin: 0; }

/* Article */
.article-content {
  max-width: 760px;
  margin: 0 auto;
  padding: 3rem var(--space);
  font-size: 1.125rem;
  line-height: 1.75;
}
.article-content h2 { margin-top: 2.5rem; }
.article-content p { margin: 1rem 0; }

/* Sidebar */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}
.widget {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow-sm);
}
.widget h3 {
  font-size: 1rem;
  font-weight: 700;
  margin: 0 0 0.75rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--primary-light);
}
.widget ul { padding: 0; list-style: none; }
.widget li { margin: 0.5rem 0; padding: 0.35rem 0; border-bottom: 1px solid var(--border); }
.widget li:last-child { border-bottom: 0; }
.widget a { color: var(--text-secondary); }
.widget a:hover { color: var(--primary); }

/* Footer */
.site-footer {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  padding: 3rem 0 2rem;
  margin-top: 4rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}
.footer-grid h4 { margin-bottom: 1rem; }
.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid var(--border);
  text-align: center;
  color: var(--muted);
  font-size: 0.9rem;
}
@media (max-width: 768px) {
  .footer-grid { grid-template-columns: 1fr; gap: 2rem; }
}

/* RTL Support */
.rtl { direction: rtl; text-align: right; }
.rtl .hero { direction: rtl; }
[dir="rtl"] { font-family: system-ui, -apple-system, 'Segoe UI', Roboto, 'Noto Sans Arabic', sans-serif; }

/* Utilities */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
.text-center { text-align: center; }
.mb-1 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 2rem; }
.mt-2 { margin-top: 2rem; }
