/* === electriclunchboxguide.com — Mobile-First Stylesheet === */
/* Target: 90+ PageSpeed, minimal CSS, no frameworks */

/* ----- CSS Custom Properties ----- */
:root {
  --green-700: #2d6a4f;
  --green-600: #40916c;
  --green-500: #52b788;
  --green-200: #d8f3dc;
  --green-100: #f0fdf4;
  --gray-900: #1a1a2e;
  --gray-700: #4a4a5a;
  --gray-500: #7a7a8a;
  --gray-200: #e8e8ec;
  --gray-100: #f5f5f7;
  --white: #ffffff;
  --orange-500: #e67e22;
  --orange-600: #d35400;
  --red-500: #e74c3c;

  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, sans-serif;
  --font-serif: Georgia, "Times New Roman", serif;

  --max-w: 1100px;
  --radius: 8px;
  --shadow: 0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.06);
  --shadow-lg: 0 4px 12px rgba(0,0,0,0.1);
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  color: var(--gray-900);
  background: var(--gray-100);
  line-height: 1.7;
}

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

a { color: var(--green-700); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 { line-height: 1.3; color: var(--gray-900); }
h1 { font-size: 1.75rem; }
h2 { font-size: 1.4rem; }
h3 { font-size: 1.15rem; }

ul, ol { padding-left: 1.25rem; }
li + li { margin-top: 0.35rem; }

/* ----- Layout ----- */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1rem;
}

/* ----- Header / Nav ----- */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  padding: 0.75rem 0;
  position: sticky;
  top: 0;
  z-index: 100;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.logo {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--green-700);
  text-decoration: none;
  white-space: nowrap;
}
.logo:hover { text-decoration: none; }

.nav-links {
  display: flex;
  gap: 0.25rem;
  flex-wrap: wrap;
}

.nav-links a {
  display: inline-block;
  padding: 0.35rem 0.65rem;
  font-size: 0.875rem;
  color: var(--gray-700);
  border-radius: 4px;
  transition: background 0.15s;
}
.nav-links a:hover,
.nav-links a.active {
  background: var(--green-100);
  color: var(--green-700);
  text-decoration: none;
}

/* Mobile hamburger hidden by default — show via JS if needed */
.nav-toggle { display: none; }

/* ----- Hero ----- */
.hero {
  background: linear-gradient(135deg, var(--green-700), var(--green-500));
  color: var(--white);
  padding: 2.5rem 0;
  text-align: center;
}

.hero h1 {
  font-size: 1.75rem;
  color: var(--white);
  margin-bottom: 0.75rem;
}

.hero p {
  font-size: 1.05rem;
  opacity: 0.92;
  max-width: 600px;
  margin: 0 auto;
}

/* ----- Cards Grid ----- */
.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
  padding: 2rem 0;
}

.card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: box-shadow 0.2s;
  display: flex;
  flex-direction: column;
}
.card:hover { box-shadow: var(--shadow-lg); }

.card-img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  background: var(--green-200);
}

.card-body { padding: 1rem 1.15rem; flex: 1; display: flex; flex-direction: column; }

.card-body h3 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}
.card-body h3 a { color: var(--gray-900); }
.card-body h3 a:hover { color: var(--green-700); }

.card-body p {
  font-size: 0.9rem;
  color: var(--gray-700);
  flex: 1;
  margin-bottom: 0.75rem;
}

.card-meta {
  font-size: 0.8rem;
  color: var(--gray-500);
}

.card-tag {
  display: inline-block;
  background: var(--green-100);
  color: var(--green-700);
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
}

/* ----- Content Pages ----- */
.content-page {
  background: var(--white);
  padding: 2rem 1.25rem;
  margin: 1.5rem 0;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.content-page h1 {
  font-size: 1.75rem;
  margin-bottom: 0.5rem;
}

.content-page .byline {
  font-size: 0.85rem;
  color: var(--gray-500);
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--gray-200);
}

.content-page h2 {
  margin-top: 1.75rem;
  margin-bottom: 0.75rem;
  padding-bottom: 0.4rem;
  border-bottom: 2px solid var(--green-200);
}

.content-page h3 {
  margin-top: 1.25rem;
  margin-bottom: 0.5rem;
}

.content-page p {
  margin-bottom: 1rem;
}

.content-page ul, .content-page ol {
  margin-bottom: 1rem;
}

/* ----- Comparison Table ----- */
.comparison-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.25rem 0;
  font-size: 0.9rem;
  overflow-x: auto;
  display: block;
}

.comparison-table thead {
  background: var(--green-700);
  color: var(--white);
}

.comparison-table th {
  padding: 0.65rem 0.75rem;
  text-align: left;
  font-weight: 600;
  white-space: nowrap;
}

.comparison-table td {
  padding: 0.6rem 0.75rem;
  border-bottom: 1px solid var(--gray-200);
}

.comparison-table tbody tr:hover {
  background: var(--green-100);
}

/* Table wrapper for horizontal scroll on mobile */
.table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 1.25rem 0;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
}

.table-wrap .comparison-table {
  margin: 0;
  display: table;
}

/* ----- Product Review Card ----- */
.review-card {
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 1.25rem;
  margin-bottom: 1.5rem;
  background: var(--white);
}

.review-card .pros-cons {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
  margin: 1rem 0;
}

.pros, .cons {
  padding: 0.75rem;
  border-radius: 6px;
}

.pros { background: var(--green-100); }
.cons { background: #fef2f2; }

.pros h4 { color: var(--green-700); }
.cons h4 { color: var(--red-500); }

/* ----- CTA / Affiliate Button ----- */
.btn-affiliate {
  display: inline-block;
  background: var(--orange-500);
  color: var(--white);
  padding: 0.65rem 1.5rem;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.95rem;
  text-align: center;
  transition: background 0.15s, transform 0.1s;
  border: none;
  cursor: pointer;
}
.btn-affiliate:hover {
  background: var(--orange-600);
  text-decoration: none;
  transform: translateY(-1px);
}

.btn-affiliate-lg {
  padding: 0.8rem 2rem;
  font-size: 1.05rem;
}

/* ----- Breadcrumbs ----- */
.breadcrumbs {
  font-size: 0.85rem;
  color: var(--gray-500);
  margin-bottom: 1rem;
  padding: 0.5rem 0;
}
.breadcrumbs a { color: var(--gray-700); }
.breadcrumbs span { color: var(--gray-500); }

/* ----- Disclosure Box ----- */
.disclosure-box {
  background: var(--gray-100);
  border-left: 4px solid var(--green-500);
  padding: 0.75rem 1rem;
  margin: 1rem 0;
  font-size: 0.85rem;
  color: var(--gray-700);
  border-radius: 0 4px 4px 0;
}

/* ----- Footer ----- */
.site-footer {
  background: var(--gray-900);
  color: var(--gray-500);
  padding: 2rem 0 1.5rem;
  margin-top: 2rem;
  font-size: 0.875rem;
}

.site-footer .container {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

.footer-brand h3 {
  color: var(--white);
  font-size: 1.1rem;
  margin-bottom: 0.4rem;
}

.footer-links h4 {
  color: var(--white);
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
}

.footer-links ul {
  list-style: none;
  padding: 0;
}

.footer-links li + li { margin-top: 0.3rem; }

.footer-links a { color: var(--gray-500); }
.footer-links a:hover { color: var(--white); }

.footer-bottom {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  text-align: center;
  font-size: 0.8rem;
}

/* ----- Pagination ----- */
.pagination {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  padding: 1.5rem 0;
}

.pagination a, .pagination span {
  display: inline-block;
  padding: 0.4rem 0.75rem;
  border-radius: 4px;
  border: 1px solid var(--gray-200);
  font-size: 0.875rem;
}

.pagination a { background: var(--white); }
.pagination .current { background: var(--green-700); color: var(--white); border-color: var(--green-700); }

/* ----- Featured / Large Card ----- */
.featured-card {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  margin-bottom: 1.5rem;
}

.featured-card .featured-img {
  height: 200px;
  object-fit: cover;
  background: var(--green-200);
}

.featured-card .featured-body {
  padding: 1.25rem;
}

.featured-card h2 {
  margin-bottom: 0.5rem;
}
.featured-card h2 a { color: var(--gray-900); }
.featured-card h2 a:hover { color: var(--green-700); }

/* ----- Newsletter CTA ----- */
.newsletter-cta {
  background: var(--green-100);
  border: 1px solid var(--green-200);
  border-radius: var(--radius);
  padding: 1.5rem;
  text-align: center;
  margin: 2rem 0;
}

.newsletter-cta h3 { margin-bottom: 0.5rem; }
.newsletter-cta p { font-size: 0.9rem; color: var(--gray-700); margin-bottom: 1rem; }

.newsletter-form {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.newsletter-form input[type="email"] {
  padding: 0.6rem 0.75rem;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  font-size: 0.95rem;
  width: 100%;
}

.newsletter-form button {
  background: var(--green-700);
  color: var(--white);
  border: none;
  padding: 0.6rem 1.25rem;
  border-radius: var(--radius);
  font-weight: 600;
  cursor: pointer;
  font-size: 0.95rem;
}
.newsletter-form button:hover { background: var(--green-600); }

/* ----- Categories Section on Homepage ----- */
.category-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
  margin: 1.5rem 0;
}

.category-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 1.25rem;
  text-align: center;
  transition: border-color 0.15s;
}
.category-card:hover { border-color: var(--green-500); }

.category-card .cat-icon {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.category-card h3 {
  font-size: 1rem;
  margin-bottom: 0.25rem;
}
.category-card h3 a { color: var(--gray-900); }

.category-card p {
  font-size: 0.85rem;
  color: var(--gray-500);
}

/* ----- Utility ----- */
.text-center { text-align: center; }
.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.mb-1 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 2rem; }
.section-title { margin-bottom: 1rem; }

/* ----- Product Grid (for reviews) ----- */
.product-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
  margin: 1.5rem 0;
}

.product-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 1rem;
  text-align: center;
  transition: box-shadow 0.2s;
}
.product-card:hover { box-shadow: var(--shadow-lg); }

.product-card .product-img {
  height: 150px;
  background: var(--green-200);
  border-radius: 4px;
  margin-bottom: 0.75rem;
}

.product-card h4 {
  font-size: 0.95rem;
  margin-bottom: 0.3rem;
}

.product-card .price {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--green-700);
  margin: 0.4rem 0;
}

.product-card .rating {
  color: var(--orange-500);
  font-size: 0.9rem;
  margin-bottom: 0.75rem;
}

/* ----- Schema Markup & Structured Data tags (invisible) ----- */
/* All schema.org data uses JSON-LD in head, no visible CSS needed */

/* ----- Responsive: Tablet (480px+) ----- */
@media (min-width: 480px) {
  h1 { font-size: 2rem; }
  .hero h1 { font-size: 2rem; }
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .category-grid { grid-template-columns: repeat(2, 1fr); }
  .product-grid { grid-template-columns: repeat(2, 1fr); }
  .review-card .pros-cons { grid-template-columns: 1fr 1fr; }
  .newsletter-form { flex-direction: row; }
  .site-footer .container { grid-template-columns: 1fr 1fr; }
}

/* ----- Responsive: Desktop (768px+) ----- */
@media (min-width: 768px) {
  h1 { font-size: 2.25rem; }
  h2 { font-size: 1.6rem; }
  h3 { font-size: 1.25rem; }

  .hero { padding: 3.5rem 0; }
  .hero h1 { font-size: 2.5rem; }
  .hero p { font-size: 1.15rem; }

  .card-grid { grid-template-columns: repeat(3, 1fr); }
  .category-grid { grid-template-columns: repeat(3, 1fr); }
  .product-grid { grid-template-columns: repeat(3, 1fr); }

  .featured-card { flex-direction: row; }
  .featured-card .featured-img { width: 300px; height: auto; flex-shrink: 0; }

  .content-page { padding: 2.5rem; }

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

  .container { padding: 0 1.5rem; }
}

/* ----- Print ----- */
@media print {
  .site-header, .site-footer, .btn-affiliate, .newsletter-cta { display: none; }
  body { background: var(--white); color: #000; }
  .content-page { box-shadow: none; border: none; }
}
