/* contractorapps.co — shared stylesheet */
:root {
  --brand: #e8500a;
  --brand-dark: #c43d00;
  --ink: #1a1a1a;
  --ink-muted: #555;
  --bg: #fff;
  --bg-alt: #f7f6f4;
  --border: #e2e0dc;
  --radius: 8px;
  --max: 780px;
  --sans: 'Inter', system-ui, -apple-system, sans-serif;
}

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

html { font-size: 16px; scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.7;
}

/* ── Nav ── */
.site-nav {
  border-bottom: 1px solid var(--border);
  padding: 0 24px;
  background: #fff;
  position: sticky;
  top: 0;
  z-index: 50;
}
.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 58px;
}
.nav-logo {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.5px;
}
.nav-logo span { color: var(--brand); }
.nav-links { display: flex; gap: 28px; list-style: none; }
.nav-links a {
  text-decoration: none;
  color: var(--ink-muted);
  font-size: 0.88rem;
  font-weight: 500;
  transition: color 0.15s;
}
.nav-links a:hover { color: var(--brand); }

/* ── Page wrapper ── */
.page-wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 48px 24px 80px;
}

/* ── Hero (homepage) ── */
.hero {
  background: var(--bg-alt);
  padding: 64px 24px;
  text-align: center;
  border-bottom: 1px solid var(--border);
}
.hero h1 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -1px;
  line-height: 1.2;
  max-width: 640px;
  margin: 0 auto 16px;
}
.hero p {
  color: var(--ink-muted);
  max-width: 520px;
  margin: 0 auto 28px;
  font-size: 1.05rem;
}
.hero-badge {
  display: inline-block;
  background: #fff3ee;
  color: var(--brand);
  border: 1px solid #f5c4ae;
  border-radius: 999px;
  padding: 4px 14px;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 18px;
}

/* ── Cards ── */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
  max-width: 1100px;
  margin: 0 auto;
  padding: 48px 24px;
}
.card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  text-decoration: none;
  color: var(--ink);
  transition: box-shadow 0.15s, transform 0.1s;
  background: #fff;
  display: flex;
  flex-direction: column;
}
.card:hover { box-shadow: 0 4px 20px rgba(0,0,0,0.08); transform: translateY(-2px); }
.card-tag {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--brand);
  margin-bottom: 10px;
}
.card h3 { font-size: 1rem; font-weight: 700; line-height: 1.3; margin-bottom: 8px; }
.card p { font-size: 0.85rem; color: var(--ink-muted); flex: 1; }
.card-arrow { margin-top: 14px; color: var(--brand); font-size: 0.82rem; font-weight: 600; }

/* ── Article ── */
.article-header { margin-bottom: 36px; }
.article-tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--brand);
  margin-bottom: 12px;
}
.article-header h1 {
  font-size: clamp(1.5rem, 3.5vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.5px;
  line-height: 1.25;
  margin-bottom: 12px;
}
.article-meta {
  font-size: 0.82rem;
  color: var(--ink-muted);
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  align-items: center;
}
.article-meta span { display: flex; align-items: center; gap: 4px; }

/* ── Prose ── */
.prose h2 {
  font-size: 1.3rem;
  font-weight: 800;
  letter-spacing: -0.3px;
  margin: 40px 0 12px;
  padding-top: 8px;
  border-top: 2px solid var(--border);
}
.prose h3 { font-size: 1.05rem; font-weight: 700; margin: 28px 0 8px; }
.prose p { margin-bottom: 16px; }
.prose ul, .prose ol { padding-left: 22px; margin-bottom: 16px; }
.prose li { margin-bottom: 6px; }
.prose strong { font-weight: 700; }
.prose a { color: var(--brand); text-decoration: underline; text-underline-offset: 2px; }
.prose a:hover { color: var(--brand-dark); }

/* ── Winner box ── */
.winner-box {
  background: #fff8f5;
  border: 2px solid var(--brand);
  border-radius: var(--radius);
  padding: 22px 24px;
  margin: 28px 0;
}
.winner-box .label { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--brand); margin-bottom: 6px; }
.winner-box h3 { font-size: 1.1rem; font-weight: 800; margin-bottom: 6px; }
.winner-box p { font-size: 0.88rem; color: var(--ink-muted); margin: 0; }

/* ── CTA button ── */
.cta-btn {
  display: inline-block;
  background: var(--brand);
  color: #fff;
  padding: 12px 24px;
  border-radius: var(--radius);
  font-weight: 700;
  font-size: 0.92rem;
  text-decoration: none;
  transition: background 0.15s, transform 0.1s;
}
.cta-btn:hover { background: var(--brand-dark); transform: translateY(-1px); }
.cta-btn.secondary { background: #fff; color: var(--brand); border: 2px solid var(--brand); }
.cta-btn.secondary:hover { background: #fff8f5; }

/* ── Comparison table ── */
.comp-table-wrap { overflow-x: auto; margin: 24px 0; }
.comp-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}
.comp-table th {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  padding: 12px 14px;
  font-weight: 700;
  text-align: left;
  white-space: nowrap;
}
.comp-table td {
  border: 1px solid var(--border);
  padding: 11px 14px;
  vertical-align: top;
}
.comp-table tr:hover td { background: #fafaf8; }
.comp-table .check { color: #22a06b; font-weight: 700; }
.comp-table .cross { color: #c00; }
.comp-table .highlight th, .comp-table .highlight td { background: #fff8f5; }

/* ── Rating ── */
.rating-row { display: flex; align-items: center; gap: 8px; margin: 6px 0; font-size: 0.88rem; }
.rating-bar-wrap { flex: 1; height: 7px; background: var(--border); border-radius: 999px; overflow: hidden; }
.rating-bar { height: 100%; background: var(--brand); border-radius: 999px; }
.rating-label { width: 120px; color: var(--ink-muted); font-size: 0.8rem; }
.rating-val { width: 30px; font-weight: 700; font-size: 0.82rem; text-align: right; }

/* ── Disclosure ── */
.disclosure {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 18px;
  font-size: 0.78rem;
  color: var(--ink-muted);
  margin-bottom: 32px;
  line-height: 1.5;
}

/* ── TOC ── */
.toc {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  margin-bottom: 36px;
}
.toc h4 { font-size: 0.82rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--ink-muted); margin-bottom: 10px; }
.toc ol { padding-left: 18px; }
.toc li { margin-bottom: 4px; }
.toc a { color: var(--brand); font-size: 0.88rem; text-decoration: none; }
.toc a:hover { text-decoration: underline; }

/* ── Score card ── */
.score-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 24px;
  margin: 20px 0;
}
.score-card h3 { font-size: 1rem; font-weight: 800; margin-bottom: 4px; }
.score-card .score-num { font-size: 2rem; font-weight: 800; color: var(--brand); line-height: 1; margin-bottom: 14px; }
.score-card .score-num span { font-size: 1rem; color: var(--ink-muted); font-weight: 400; }

/* ── Footer ── */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 32px 24px;
  text-align: center;
  font-size: 0.8rem;
  color: var(--ink-muted);
  background: var(--bg-alt);
}
.site-footer a { color: var(--ink-muted); text-decoration: underline; }
.footer-links { display: flex; gap: 20px; justify-content: center; margin-bottom: 12px; flex-wrap: wrap; }

/* ── Responsive ── */
@media (max-width: 640px) {
  .nav-links { display: none; }
  .page-wrap { padding: 32px 16px 60px; }
  .hero { padding: 40px 16px; }
  .card-grid { padding: 32px 16px; }
}
