/*
Theme Name: 3DExaminer
Theme URI: https://3dexaminer.com
Author: Wyatt Sanders
Description: Custom theme for 3D printer reviews and comparisons
Version: 2.0.0
Text Domain: 3dexaminer
*/

:root {
  --bg-dark: #0d1117;
  --bg-card: #161b22;
  --bg-card-hover: #1c2333;
  --border: #30363d;
  --text-primary: #e6edf3;
  --text-secondary: #8b949e;
  --accent: #f97316;
  --accent-hover: #fb923c;
  --accent-2: #3b82f6;
  --accent-2-hover: #60a5fa;
  --green: #22c55e;
  --red: #ef4444;
  --yellow: #eab308;
  --rating-excellent: #22c55e;
  --rating-great: #84cc16;
  --rating-good: #eab308;
  --rating-average: #f97316;
  --rating-poor: #ef4444;
  --font-heading: 'Orbitron', sans-serif;
  --font-body: 'Inter', -apple-system, sans-serif;
  --header-height: 72px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: var(--font-body);
  background: var(--bg-dark);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background: rgba(13, 17, 23, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  z-index: 1000;
  transition: box-shadow 0.3s;
}
.site-header.scrolled { box-shadow: 0 4px 20px rgba(0,0,0,0.4); }
.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.site-logo {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--accent);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 8px;
}
.site-logo .logo-icon {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

/* Nav */
.primary-nav { display: flex; align-items: center; gap: 8px; }
.primary-nav a {
  color: var(--text-secondary);
  text-decoration: none;
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.2s;
}
.primary-nav a:hover,
.primary-nav a.active {
  color: var(--text-primary);
  background: rgba(249, 115, 22, 0.1);
}
.mobile-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 8px;
}
@media (max-width: 900px) {
  .mobile-toggle { display: block; }
  .primary-nav {
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    background: var(--bg-card);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 16px;
    gap: 4px;
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s;
  }
  .primary-nav.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
  }
  .primary-nav a { padding: 12px 16px; width: 100%; }
}

/* Hero */
.hero {
  margin-top: var(--header-height);
  padding: 80px 24px;
  text-align: center;
  background: linear-gradient(180deg, rgba(249,115,22,0.08) 0%, var(--bg-dark) 100%);
}
.hero h1 {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 5vw, 3.2rem);
  margin-bottom: 16px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hero p {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 32px;
}
.hero-buttons { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s;
  font-size: 0.95rem;
}
.btn-primary {
  background: var(--accent);
  color: #000;
}
.btn-primary:hover { background: var(--accent-hover); transform: translateY(-2px); }
.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border);
}
.btn-secondary:hover { border-color: var(--accent); color: var(--accent); }

/* Sections */
.section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 60px 24px;
}
.section-title {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  margin-bottom: 8px;
}
.section-subtitle {
  color: var(--text-secondary);
  margin-bottom: 32px;
}

/* Review Grid */
.review-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 24px;
}
.review-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s;
}
.review-card:hover {
  transform: translateY(-4px);
  border-color: var(--accent);
  box-shadow: 0 8px 32px rgba(249,115,22,0.1);
}
.review-card-image {
  width: 100%;
  height: 200px;
  background: linear-gradient(135deg, var(--bg-card-hover), var(--bg-dark));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: var(--text-secondary);
}
.review-card-body { padding: 20px; }
.review-card-category {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--accent);
  margin-bottom: 8px;
}
.review-card-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-primary);
}
.review-card-title a { color: inherit; text-decoration: none; }
.review-card-title a:hover { color: var(--accent); }
.review-card-excerpt {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 12px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.review-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.rating-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-weight: 700;
  font-size: 0.9rem;
  color: #000;
}
.rating-9, .rating-10 { background: var(--rating-excellent); }
.rating-7, .rating-8 { background: var(--rating-great); }
.rating-5, .rating-6 { background: var(--rating-good); }
.rating-3, .rating-4 { background: var(--rating-average); }
.rating-1, .rating-2 { background: var(--rating-poor); }
.review-date { font-size: 0.8rem; color: var(--text-secondary); }

/* Spec Table */
.spec-table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
}
.spec-table th,
.spec-table td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}
.spec-table th {
  background: var(--bg-card);
  font-weight: 600;
  color: var(--accent);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.spec-table tr:hover td { background: var(--bg-card-hover); }

/* Pros/Cons */
.pros-cons { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin: 24px 0; }
.pros, .cons {
  padding: 20px;
  border-radius: 8px;
}
.pros { background: rgba(34,197,94,0.08); border-left: 4px solid var(--green); }
.cons { background: rgba(239,68,68,0.08); border-left: 4px solid var(--red); }
.pros h4 { color: var(--green); margin-bottom: 12px; }
.cons h4 { color: var(--red); margin-bottom: 12px; }
.pros li, .cons li {
  margin-bottom: 6px;
  font-size: 0.95rem;
  list-style: none;
  padding-left: 20px;
  position: relative;
}
.pros li::before { content: '+'; color: var(--green); position: absolute; left: 0; font-weight: 700; }
.cons li::before { content: '-'; color: var(--red); position: absolute; left: 0; font-weight: 700; }

/* Buy Box */
.buy-box {
  background: var(--bg-card);
  border: 2px solid var(--accent);
  border-radius: 12px;
  padding: 24px;
  margin: 32px 0;
}
.buy-box h4 {
  font-size: 1.2rem;
  margin-bottom: 8px;
}
.buy-box .price {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 16px;
}
.buy-btn {
  display: inline-block;
  padding: 14px 32px;
  background: var(--accent);
  color: #000;
  font-weight: 700;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.2s;
}
.buy-btn:hover { background: var(--accent-hover); transform: translateY(-2px); }

/* Regulations / Info Section */
.info-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}
.info-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px;
  transition: all 0.3s;
}
.info-card:hover { border-color: var(--accent-2); transform: translateY(-2px); }
.info-card-icon { font-size: 2rem; margin-bottom: 12px; }
.info-card h3 { font-size: 1.1rem; margin-bottom: 8px; }
.info-card p { font-size: 0.9rem; color: var(--text-secondary); }

/* Newsletter */
.newsletter {
  background: linear-gradient(135deg, rgba(249,115,22,0.1), rgba(59,130,246,0.1));
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 48px 24px;
  text-align: center;
  margin: 40px 0;
}
.newsletter h3 {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  margin-bottom: 8px;
}
.newsletter p { color: var(--text-secondary); margin-bottom: 24px; }
.newsletter-form {
  display: flex;
  gap: 12px;
  max-width: 480px;
  margin: 0 auto;
}
.newsletter-form input {
  flex: 1;
  padding: 12px 16px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text-primary);
  font-size: 0.95rem;
}
.newsletter-form input:focus { outline: none; border-color: var(--accent); }
.newsletter-form button {
  padding: 12px 24px;
  background: var(--accent);
  color: #000;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}
.newsletter-form button:hover { background: var(--accent-hover); }
@media (max-width: 500px) {
  .newsletter-form { flex-direction: column; }
}

/* Footer */
.site-footer {
  background: var(--bg-card);
  border-top: 1px solid var(--border);
  padding: 48px 24px 24px;
  margin-top: 60px;
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
}
@media (max-width: 768px) {
  .footer-inner { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 500px) {
  .footer-inner { grid-template-columns: 1fr; }
}
.footer-brand h3 {
  font-family: var(--font-heading);
  color: var(--accent);
  margin-bottom: 12px;
}
.footer-brand p { color: var(--text-secondary); font-size: 0.9rem; }
.footer-col h4 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-secondary);
  margin-bottom: 16px;
}
.footer-col a {
  display: block;
  color: var(--text-primary);
  text-decoration: none;
  padding: 4px 0;
  font-size: 0.9rem;
  transition: color 0.2s;
}
.footer-col a:hover { color: var(--accent); }
.footer-bottom {
  max-width: 1200px;
  margin: 32px auto 0;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  text-align: center;
  color: var(--text-secondary);
  font-size: 0.85rem;
}

/* Page Content */
.page-content {
  max-width: 800px;
  margin: calc(var(--header-height) + 40px) auto 60px;
  padding: 0 24px;
}
.page-content h1 {
  font-family: var(--font-heading);
  font-size: 2rem;
  margin-bottom: 24px;
  color: var(--accent);
}
.page-content h2 { margin: 32px 0 16px; font-size: 1.4rem; }
.page-content h3 { margin: 24px 0 12px; font-size: 1.2rem; }
.page-content p { margin-bottom: 16px; color: var(--text-secondary); }
.page-content ul, .page-content ol { margin: 0 0 16px 24px; color: var(--text-secondary); }
.page-content li { margin-bottom: 8px; }
.page-content a { color: var(--accent); }
.page-content img { max-width: 100%; border-radius: 8px; margin: 16px 0; }
.page-content blockquote {
  border-left: 4px solid var(--accent);
  padding: 16px 24px;
  margin: 24px 0;
  background: var(--bg-card);
  border-radius: 0 8px 8px 0;
  font-style: italic;
  color: var(--text-secondary);
}

/* Single post / review */
.single-header {
  margin-top: var(--header-height);
  padding: 40px 24px;
  text-align: center;
  background: linear-gradient(180deg, rgba(249,115,22,0.06) 0%, var(--bg-dark) 100%);
}
.single-header h1 {
  font-family: var(--font-heading);
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  max-width: 800px;
  margin: 0 auto 12px;
}
.single-meta {
  color: var(--text-secondary);
  font-size: 0.9rem;
}
.single-body {
  max-width: 800px;
  margin: 0 auto 60px;
  padding: 0 24px;
}
.single-body p { margin-bottom: 16px; color: var(--text-secondary); line-height: 1.8; }
.single-body h2 { color: var(--text-primary); margin: 32px 0 16px; font-size: 1.5rem; }
.single-body h3 { color: var(--text-primary); margin: 24px 0 12px; }
.single-body ul, .single-body ol { margin: 0 0 16px 24px; color: var(--text-secondary); }
.single-body li { margin-bottom: 8px; }
.single-body a { color: var(--accent); text-decoration: none; }
.single-body a:hover { text-decoration: underline; }
.single-body img { max-width: 100%; border-radius: 8px; margin: 16px 0; }
.single-body blockquote {
  border-left: 4px solid var(--accent);
  padding: 16px 24px;
  margin: 24px 0;
  background: var(--bg-card);
  border-radius: 0 8px 8px 0;
  font-style: italic;
  color: var(--text-secondary);
}

/* Pagination */
.pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin: 32px 0;
}
.pagination a, .pagination span {
  padding: 8px 16px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.2s;
}
.pagination a {
  background: var(--bg-card);
  color: var(--text-primary);
  border: 1px solid var(--border);
}
.pagination a:hover { border-color: var(--accent); }
.pagination .current {
  background: var(--accent);
  color: #000;
}

/* Toast */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--green);
  color: #000;
  padding: 12px 24px;
  border-radius: 8px;
  font-weight: 600;
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.3s;
  z-index: 9999;
}
.toast.show { transform: translateY(0); opacity: 1; }
