/*
Theme Name: WAIpress Default
Theme URI: https://waipress.danielmoya.cv
Author: WAIpress
Author URI: https://danielmoya.cv
Description: Default theme for WAIpress - AI-driven content management platform. Clean, modern design with native chatbot widget support.
Version: 1.0.0
Requires at least: 6.7
Tested up to: 6.7
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: waipress-default
Tags: blog, one-column, custom-colors, custom-menu, featured-images, full-width-template, threaded-comments, translation-ready
*/

/* === Reset & Base === */
:root {
  --wai-primary: #2271b1;
  --wai-primary-dark: #135e96;
  --wai-accent: #6366f1;
  --wai-bg: #ffffff;
  --wai-bg-alt: #f8f9fa;
  --wai-text: #1d2327;
  --wai-text-light: #646970;
  --wai-border: #e2e4e7;
  --wai-success: #00a32a;
  --wai-danger: #d63638;
  --wai-radius: 8px;
  --wai-max-width: 1200px;
  --wai-font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

body {
  font-family: var(--wai-font);
  color: var(--wai-text);
  background: var(--wai-bg);
  line-height: 1.7;
  margin: 0;
  font-size: 16px;
}

a { color: var(--wai-primary); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--wai-primary-dark); }

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

/* === Layout === */
.wai-container {
  max-width: var(--wai-max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* === Header === */
.wai-header {
  background: var(--wai-bg);
  border-bottom: 1px solid var(--wai-border);
  padding: 16px 0;
  position: sticky;
  top: 0;
  z-index: 100;
}

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

.wai-logo {
  font-size: 22px;
  font-weight: 700;
  color: var(--wai-text);
}

.wai-logo:hover { color: var(--wai-primary); }

.wai-nav { display: flex; gap: 24px; align-items: center; }
.wai-nav a { color: var(--wai-text-light); font-size: 15px; font-weight: 500; }
.wai-nav a:hover { color: var(--wai-primary); }

/* === Hero === */
.wai-hero {
  padding: 80px 0;
  text-align: center;
  background: linear-gradient(135deg, #f0f4ff 0%, #fdf2f8 100%);
}

.wai-hero h1 {
  font-size: 48px;
  font-weight: 800;
  line-height: 1.2;
  margin: 0 0 16px;
}

.wai-hero p {
  font-size: 20px;
  color: var(--wai-text-light);
  max-width: 600px;
  margin: 0 auto;
}

/* === Content === */
.wai-content {
  padding: 48px 0;
}

/* === Blog Cards === */
.wai-posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 32px;
}

.wai-post-card {
  background: var(--wai-bg);
  border: 1px solid var(--wai-border);
  border-radius: var(--wai-radius);
  overflow: hidden;
  transition: box-shadow 0.3s, transform 0.2s;
}

.wai-post-card:hover {
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
  transform: translateY(-2px);
}

.wai-post-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.wai-post-card-body {
  padding: 20px;
}

.wai-post-card h2 {
  font-size: 20px;
  margin: 0 0 8px;
  line-height: 1.3;
}

.wai-post-card h2 a { color: var(--wai-text); }
.wai-post-card h2 a:hover { color: var(--wai-primary); }

.wai-post-card .wai-meta {
  font-size: 13px;
  color: var(--wai-text-light);
  margin-bottom: 12px;
}

.wai-post-card .wai-excerpt {
  color: var(--wai-text-light);
  font-size: 15px;
  line-height: 1.6;
}

.wai-read-more {
  display: inline-block;
  margin-top: 12px;
  color: var(--wai-primary);
  font-weight: 600;
  font-size: 14px;
}

/* === Single Post === */
.wai-single {
  max-width: 760px;
  margin: 0 auto;
  padding: 48px 24px;
}

.wai-single h1 {
  font-size: 40px;
  font-weight: 800;
  line-height: 1.2;
  margin: 0 0 16px;
}

.wai-single .wai-meta {
  font-size: 14px;
  color: var(--wai-text-light);
  margin-bottom: 32px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--wai-border);
}

.wai-single .entry-content {
  font-size: 18px;
  line-height: 1.8;
}

.wai-single .entry-content h2 { font-size: 28px; margin-top: 40px; }
.wai-single .entry-content h3 { font-size: 22px; margin-top: 32px; }
.wai-single .entry-content p { margin-bottom: 20px; }
.wai-single .entry-content blockquote {
  border-left: 4px solid var(--wai-primary);
  padding: 12px 24px;
  margin: 24px 0;
  background: var(--wai-bg-alt);
  border-radius: 0 var(--wai-radius) var(--wai-radius) 0;
}

/* === Comments === */
.wai-comments { margin-top: 48px; padding-top: 32px; border-top: 1px solid var(--wai-border); }
.wai-comments h2 { font-size: 24px; margin-bottom: 24px; }
.comment { margin-bottom: 24px; padding: 16px; background: var(--wai-bg-alt); border-radius: var(--wai-radius); }
.comment-author { font-weight: 600; }
.comment-content { margin-top: 8px; }

/* === Footer === */
.wai-footer {
  background: var(--wai-text);
  color: rgba(255,255,255,0.7);
  padding: 40px 0;
  margin-top: 64px;
}

.wai-footer a { color: rgba(255,255,255,0.9); }
.wai-footer a:hover { color: #fff; }

.wai-footer .wai-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* === Pagination === */
.wai-pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 48px;
}

.wai-pagination a, .wai-pagination span {
  padding: 8px 16px;
  border: 1px solid var(--wai-border);
  border-radius: var(--wai-radius);
  font-size: 14px;
}

.wai-pagination .current {
  background: var(--wai-primary);
  color: #fff;
  border-color: var(--wai-primary);
}

/* === Responsive === */
@media (max-width: 768px) {
  .wai-hero h1 { font-size: 32px; }
  .wai-hero p { font-size: 16px; }
  .wai-posts-grid { grid-template-columns: 1fr; }
  .wai-single h1 { font-size: 28px; }
  .wai-header .wai-container { flex-wrap: wrap; gap: 12px; }
  .wai-footer .wai-container { flex-direction: column; gap: 16px; text-align: center; }
}
