/* ═══════════════════════════════════════════
   LineCalc Pro — Outdoor Professional Theme
   Shared stylesheet v1.0
   ═══════════════════════════════════════════ */

/* ── Design Tokens ── */
:root {
  --primary: #1a5632;
  --primary-dark: #143d24;
  --primary-light: #2d7a4a;
  --accent: #c4882b;
  --accent-light: #e8b44f;
  --text: #1a1a1a;
  --text-secondary: #4a4a4a;
  --text-muted: #8a8a8a;
  --bg: #faf9f5;
  --bg-card: #ffffff;
  --bg-warm: #f5f0e6;
  --border: #d8d3c8;
  --radius: 8px;
  --radius-lg: 12px;
  --shadow: 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 2px 8px rgba(0,0,0,0.06);
  --shadow-lg: 0 4px 16px rgba(0,0,0,0.08);
}

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

body {
  font-family: Georgia, "Times New Roman", "Noto Serif", serif;
  font-size: 17px;
  line-height: 1.75;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

/* Headings use a clean sans-serif for contrast with the serif body */
h1, h2, h3, h4, h5, h6,
.nav-title, .nav-link, .btn-shop, .btn-cta,
.tag, .meta, footer {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, sans-serif;
}

.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ── Navigation ── */
nav {
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}
nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: inherit;
}
.nav-logo {
  width: 36px;
  height: 36px;
  background: var(--primary);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1rem;
}
.nav-brand-text {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--primary-dark);
  letter-spacing: -0.01em;
}
.nav-brand-tagline {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.nav-links { display: flex; align-items: center; gap: 28px; }
.nav-link {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  transition: color 0.2s;
}
.nav-link:hover { color: var(--primary); }

/* ── Page Header (Hero) ── */
.page-header {
  background: linear-gradient(160deg, #0d2818 0%, #1a3c28 40%, #2d5a3f 100%);
  color: #e8e0d0;
  padding: 72px 0 56px;
  text-align: center;
  border-bottom: 4px solid var(--accent);
  position: relative;
  overflow: hidden;
}
.page-header::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background:
    radial-gradient(ellipse at 20% 80%, rgba(196,136,43,0.12) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 20%, rgba(45,122,74,0.15) 0%, transparent 50%);
}
.page-header h1 {
  font-size: 2.1rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.25;
  margin-bottom: 12px;
  color: #f5efe0;
  position: relative;
}
.page-header .subtitle {
  font-size: 1.05rem;
  opacity: 0.75;
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.6;
  position: relative;
}
.page-header .meta {
  font-size: 0.82rem;
  opacity: 0.5;
  margin-top: 20px;
  position: relative;
}
.page-header .meta span { margin: 0 14px; }

/* ── Content Area ── */
.content {
  padding: 56px 0;
  background: var(--bg);
}
.article-content {
  max-width: 760px;
  margin: 0 auto;
  background: var(--bg-card);
  padding: 52px 56px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

/* Article typography */
.article-content h2 {
  font-size: 1.45rem;
  font-weight: 700;
  margin: 44px 0 16px;
  color: var(--primary-dark);
  line-height: 1.3;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--border);
}
.article-content h2:first-child { margin-top: 0; }
.article-content h3 {
  font-size: 1.15rem;
  font-weight: 600;
  margin: 28px 0 12px;
  color: var(--text);
}
.article-content p {
  margin-bottom: 20px;
  color: var(--text-secondary);
  line-height: 1.8;
}
.article-content ul, .article-content ol {
  margin: 16px 0 22px 24px;
  color: var(--text-secondary);
}
.article-content li { margin-bottom: 10px; line-height: 1.7; }
.article-content strong { color: var(--text); font-weight: 700; }
.article-content a { color: var(--primary-light); text-decoration: underline; text-underline-offset: 3px; }
.article-content a:hover { color: var(--primary-dark); }

/* Blockquote */
.article-content blockquote {
  background: var(--bg-warm);
  border-left: 4px solid var(--accent);
  padding: 18px 24px;
  margin: 28px 0;
  border-radius: 0 6px 6px 0;
  color: var(--text-secondary);
  font-style: italic;
}
.article-content blockquote p { margin-bottom: 8px; }

/* ── Components ── */

/* Table */
.table-wrap { overflow-x: auto; margin: 28px 0; }
.table-wrap table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.table-wrap th {
  background: var(--primary);
  color: #f5efe0;
  padding: 12px 16px;
  text-align: left;
  font-weight: 600;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.table-wrap td {
  padding: 11px 16px;
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
}
.table-wrap tr:nth-child(even) { background: var(--bg-warm); }

/* TOC */
.toc {
  background: var(--bg-warm);
  padding: 24px 28px;
  border-radius: var(--radius);
  margin-bottom: 36px;
  border: 1px solid var(--border);
}
.toc h2 {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 14px;
  color: var(--text-muted);
  border-bottom: none;
  padding-bottom: 0;
}
.toc ol {
  margin: 0 0 0 20px;
  font-size: 0.92rem;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.toc li { margin-bottom: 6px; color: var(--text-secondary); }

/* Product Card */
.product-card {
  background: var(--bg-warm);
  padding: 24px;
  border-radius: var(--radius);
  margin: 28px 0;
  border: 1px solid var(--border);
  border-left: 4px solid var(--accent);
}
.product-card h3 { margin: 0 0 8px; color: var(--primary-dark); font-size: 1.1rem; }
.product-card p { margin-bottom: 14px; color: var(--text-secondary); }

/* Quick Tips */
.quick-tips {
  background: linear-gradient(135deg, #eaf5ec, #dcefe0);
  padding: 24px;
  border-radius: var(--radius);
  margin: 28px 0;
  border: 1px solid #c5dcc8;
}
.quick-tips h3 { color: var(--primary-dark); margin-bottom: 12px; }
.quick-tips ul { margin: 0 0 0 20px; }
.quick-tips li { margin-bottom: 8px; }

/* FAQ */
.faq-item {
  margin-bottom: 24px;
  padding: 20px;
  background: var(--bg-warm);
  border-radius: var(--radius);
  border: 1px solid var(--border);
}
.faq-item h3 {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 10px;
}
.faq-item p { color: var(--text-secondary); margin: 0; }

/* Author box */
.author-box {
  background: var(--bg-warm);
  padding: 24px;
  border-radius: var(--radius);
  margin-top: 48px;
  display: flex;
  gap: 20px;
  align-items: center;
  border: 1px solid var(--border);
}
.author-photo {
  width: 72px; height: 72px;
  background: var(--primary);
  border-radius: 50%;
  flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  color: var(--bg-card);
  font-size: 1.6rem;
}

/* CTA */
.cta-box {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary));
  color: #f5efe0;
  padding: 36px;
  border-radius: var(--radius-lg);
  margin-top: 44px;
  text-align: center;
}
.cta-box h3 { font-size: 1.2rem; font-weight: 700; margin-bottom: 12px; }
.cta-box p { font-size: 0.95rem; opacity: 0.85; margin-bottom: 20px; }

/* Related Posts */
.related-posts {
  background: var(--bg-warm);
  padding: 24px 28px;
  border-radius: var(--radius);
  margin-top: 36px;
  border: 1px solid var(--border);
}
.related-posts h3 { margin-bottom: 14px; font-size: 0.9rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-muted); }
.related-posts ul { list-style: none; margin: 0; }
.related-posts li { margin-bottom: 10px; }
.related-posts a { color: var(--primary); text-decoration: none; font-weight: 500; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
.related-posts a:hover { text-decoration: underline; }

/* ── Buttons ── */
.btn-shop {
  display: inline-block;
  background: var(--accent);
  color: #1a1a1a;
  padding: 10px 24px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.9rem;
  transition: background 0.2s;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.btn-shop:hover { background: var(--accent-light); }

.btn-cta {
  display: inline-block;
  background: var(--accent);
  color: #1a1a1a;
  padding: 14px 32px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 700;
  font-size: 1rem;
  transition: transform 0.2s, background 0.2s;
}
.btn-cta:hover { background: var(--accent-light); transform: translateY(-1px); }

/* ── Footer ── */
footer {
  background: #0d1f14;
  color: #c0c8bb;
  padding: 56px 0 36px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 48px;
  margin-bottom: 44px;
}
.footer-brand { max-width: 300px; }
.footer-brand h4 { color: #e8e0d0; font-size: 1rem; font-weight: 700; margin-bottom: 12px; }
.footer-desc { color: #889388; font-size: 0.88rem; line-height: 1.7; }
.footer-title { font-size: 0.82rem; font-weight: 700; margin-bottom: 18px; text-transform: uppercase; letter-spacing: 0.06em; color: #a0a898; }
.footer-links { list-style: none; }
.footer-links li { margin-bottom: 10px; }
.footer-links a { color: #889388; text-decoration: none; font-size: 0.88rem; }
.footer-links a:hover { color: var(--accent-light); }
.footer-bottom {
  padding-top: 32px;
  border-top: 1px solid #1a2d1e;
  text-align: center;
  color: #667060;
  font-size: 0.82rem;
}
.footer-bottom a { color: #667060; text-decoration: none; }
.footer-bottom a:hover { color: var(--accent-light); }

/* ── Figures ── */
.article-content figure { margin: 32px 0; text-align: center; }
.article-content figure img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
}
.article-content figure figcaption {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-top: 10px;
  font-style: italic;
}

/* ── Responsive ── */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .article-content { padding: 28px 20px; border-radius: 0; border: none; }
  .page-header { padding: 48px 0 36px; }
  .page-header h1 { font-size: 1.5rem; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .content { padding: 32px 0; }
}
