/* ─── PENNY PINCHER · LIFE INSURANCE COMPARE (NerdWallet-inspired) ─── */
:root {
  --bg: #ffffff;
  --bg-soft: #f5f5f3;
  --hero-bg: #e3faf2;        /* NerdWallet green-extraLight */
  --hero-accent: #fff7ea;    /* the warm cream */
  --surface: #ffffff;
  --surface-2: #fafaf7;
  --border: rgba(15, 23, 42, 0.10);
  --border-strong: rgba(15, 23, 42, 0.16);
  --text: rgba(0, 0, 0, 0.87);
  --text-muted: #3D4045;
  --text-subtle: #6b7280;
  --primary: #008254;          /* NerdWallet green */
  --primary-hover: #006642;
  --primary-fg: #ffffff;
  --accent: #005FB9;           /* NerdWallet blue link */
  --gold: #b88a2c;
  --gold-soft: #fdf6e3;
  --gold-bar: #fbd083;
  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 16px;
  --radius-pill: 999px;
  --shadow-sm: 0 1px 2px rgba(15,23,42,.04);
  --shadow: 0 1px 2px rgba(15,23,42,.04), 0 6px 18px rgba(15,23,42,.06);
  --shadow-lg: 0 1px 2px rgba(15,23,42,.05), 0 18px 50px rgba(15,23,42,.10);
  --ring: 0 0 0 4px color-mix(in srgb, var(--primary) 22%, transparent);
  --ease: cubic-bezier(.32,.72,0,1);
  --font-sans: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-serif: 'Lora', 'Iowan Old Style', 'Times New Roman', serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font: 16px/1.55 var(--font-sans);
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  letter-spacing: -.005em;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}
@media (max-width: 720px) { .container { padding: 0 18px; } }

/* ─── NAV ─── */
.nav {
  background: #fff;
  box-shadow: 0 4px 8px rgba(0,0,0,.06);
  position: sticky; top: 0; z-index: 50;
}
.nav-inner {
  max-width: 1180px; margin: 0 auto;
  padding: 20px 24px;
  display: flex; align-items: center; justify-content: center;
}
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  color: var(--text); font-weight: 700; letter-spacing: -.01em;
  font-size: 18px;
}
.brand:hover { text-decoration: none; }
.brand img { width: 28px; height: 28px; border-radius: 6px; }
@media (max-width: 640px) { .brand span { font-size: 16px; } }

/* ─── HERO BAND ─── */
.hero-band {
  background: var(--hero-bg);
  border-bottom: 1px solid rgba(0, 130, 84, 0.12);
}
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 460px;
  gap: 48px;
  align-items: center;
  padding: 36px 24px;
}
@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; gap: 28px; padding: 32px 18px; }
  .hero-art { display: none; }
}
.hero-copy { display: flex; flex-direction: column; gap: 16px; }
.hero-disclosure { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.disclosure-link {
  background: transparent; border: 0; padding: 0; cursor: pointer;
  color: var(--accent); font-size: 13px; font-weight: 500; letter-spacing: .005em;
  font-family: var(--font-sans);
}
.disclosure-link:hover { text-decoration: underline; }
.disclosure-link:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
.ad-label {
  font-size: 12.5px; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: var(--text-muted);
}
.hero-title {
  font-family: var(--font-serif); font-weight: 500;
  font-size: clamp(34px, 5.4vw, 56px);
  line-height: 1.05; letter-spacing: -0.005em;
  margin: 4px 0 4px; color: var(--text);
}
.hero-deck {
  font-size: clamp(16px, 1.7vw, 18px); line-height: 1.55;
  color: var(--text); margin: 0; max-width: 560px;
}
.hero-trust {
  display: flex; flex-wrap: wrap; gap: 16px 22px;
  margin-top: 6px;
  font-size: 13.5px; color: var(--text-muted);
}
.trust-item { display: inline-flex; align-items: center; gap: 6px; font-weight: 500; }
.trust-item svg { color: var(--primary); flex-shrink: 0; }

.hero-art { position: relative; }
.hero-art svg {
  width: 100%; height: auto; display: block;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

/* ─── PRODUCTS SECTION ─── */
.products {
  background: #fff;
  padding: 48px 0 24px;
}
.products-head { margin-bottom: 28px; }
.products-title {
  font-family: var(--font-serif); font-weight: 600;
  font-size: clamp(22px, 2.6vw, 28px); letter-spacing: -.01em;
  margin: 0 0 8px; color: var(--text);
}
.products-sub {
  margin: 0; color: var(--text-muted); font-size: 15px;
  max-width: 720px;
}
.products-list {
  display: flex; flex-direction: column; gap: 24px;
}

/* PRODUCT CARD */
.product {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  padding: 0;
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr) 240px;
  gap: 0;
  overflow: hidden;
  transition: box-shadow 200ms var(--ease), border-color 200ms var(--ease), transform 200ms var(--ease);
}
.product:hover {
  box-shadow: var(--shadow);
  border-color: color-mix(in srgb, var(--primary) 30%, var(--border-strong));
}
.product-top-pick {
  border-color: color-mix(in srgb, var(--primary) 35%, var(--border-strong));
  box-shadow: var(--shadow);
}
@media (max-width: 880px) {
  .product { grid-template-columns: 1fr; }
}

.product-left {
  padding: 24px 22px;
  background: var(--surface-2);
  border-right: 1px solid var(--border);
  display: flex; flex-direction: column; gap: 14px;
  align-items: center; text-align: center;
  position: relative;
}
@media (max-width: 880px) {
  .product-left { border-right: 0; border-bottom: 1px solid var(--border); flex-direction: row; text-align: left; gap: 16px; }
}
.product-badge {
  position: absolute; top: 0; left: 0;
  background: var(--primary); color: white;
  font-size: 10.5px; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 0 0 8px 0;
}
.product-logo {
  width: 100%; height: 64px;
  display: flex; align-items: center; justify-content: center;
  margin-top: 8px;
}
.product-logo img {
  max-height: 56px; max-width: 100%;
  width: auto; height: auto; object-fit: contain;
}
.product-logo .logo-fallback {
  font-family: var(--font-serif);
  font-size: 20px; font-weight: 700;
  color: var(--text);
  letter-spacing: -.01em;
}
@media (max-width: 880px) {
  .product-logo { width: 120px; height: auto; flex-shrink: 0; margin-top: 0; }
  .product-logo img { max-height: 48px; }
}
.product-tag {
  display: inline-flex; align-items: center;
  font-size: 10.5px; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: var(--text-subtle);
  background: transparent; padding: 3px 0;
}
@media (max-width: 880px) {
  .product-tag { margin-left: auto; }
}
.product-rating {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
}
.product-rating .stars {
  color: var(--gold); font-size: 16px; letter-spacing: 1px; line-height: 1;
}
.product-rating .rating-num {
  font-weight: 700; color: var(--text); font-size: 18px;
  font-family: var(--font-serif);
}
.product-rating .rating-src {
  font-size: 11px; color: var(--text-muted); font-weight: 500;
}
@media (max-width: 880px) {
  .product-rating { align-items: flex-start; }
}

.product-mid {
  padding: 24px 28px;
  display: flex; flex-direction: column; gap: 12px;
  min-width: 0;
}
.product-headline {
  font-family: var(--font-serif); font-weight: 600;
  font-size: 20px; line-height: 1.25; letter-spacing: -.015em;
  margin: 0; color: var(--text);
}
.product-pros {
  margin: 4px 0 0; padding: 0; list-style: none;
  display: flex; flex-direction: column; gap: 6px;
}
.product-pros li {
  font-size: 14.5px; line-height: 1.5; color: var(--text);
  display: flex; align-items: flex-start; gap: 8px;
}
.product-pros li::before {
  content: ''; display: inline-block;
  width: 16px; height: 16px; flex-shrink: 0; margin-top: 3px;
  background: var(--primary);
  -webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'><path d='m5 12 5 5L20 7'/></svg>") center/contain no-repeat;
          mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'><path d='m5 12 5 5L20 7'/></svg>") center/contain no-repeat;
}
.product-pros li b, .product-pros li strong { font-weight: 700; color: var(--text); }
.product-drivers {
  display: flex; flex-wrap: wrap; gap: 16px 24px;
  margin-top: 4px;
  padding-top: 12px;
  border-top: 1px dashed var(--border);
}
.driver { display: flex; flex-direction: column; gap: 1px; }
.driver-label {
  font-size: 11px; font-weight: 600; letter-spacing: .06em;
  text-transform: uppercase; color: var(--text-subtle);
}
.driver-value { font-size: 14px; color: var(--text); font-weight: 600; }

.product-right {
  padding: 24px 22px;
  display: flex; flex-direction: column; gap: 10px;
  align-items: stretch; justify-content: center;
  background: var(--surface);
  border-left: 1px solid var(--border);
}
@media (max-width: 880px) {
  .product-right { border-left: 0; border-top: 1px solid var(--border); }
}

.btn-primary {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font-sans); font-weight: 600; font-size: 15px;
  padding: 14px 18px;
  background: var(--primary); color: var(--primary-fg);
  border: 0; border-radius: var(--radius);
  cursor: pointer; text-decoration: none;
  transition: background 160ms var(--ease), transform 160ms var(--ease), box-shadow 160ms var(--ease);
  box-shadow: 0 1px 2px rgba(0, 130, 84, .25), 0 4px 12px rgba(0, 130, 84, .18);
  letter-spacing: -.003em;
  text-align: center;
}
.btn-primary:hover {
  background: var(--primary-hover);
  transform: translateY(-1px);
  box-shadow: 0 1px 2px rgba(0, 130, 84, .3), 0 6px 18px rgba(0, 130, 84, .26);
  text-decoration: none;
}
.btn-primary:active { transform: translateY(0); }
.btn-primary:focus-visible { outline: none; box-shadow: var(--ring); }

.cta-sub {
  font-size: 12.5px; color: var(--text-muted); text-align: center;
  margin: 0;
}

/* ─── SKELETON ─── */
@keyframes pulse {
  0%   { opacity: 1; }
  50%  { opacity: .45; }
  100% { opacity: 1; }
}
.product-skel {
  height: 200px;
  border-radius: var(--radius-lg);
  background: rgba(0,0,0,.08);
  animation: pulse 2s ease-in-out .5s infinite;
}
@media (max-width: 880px) { .product-skel { height: 280px; } }

/* ─── ARTICLE BAND ─── */
.article-band {
  padding: 56px 0 32px;
  background: #fff;
}
.article { max-width: 760px; margin: 0 auto; }
.article .art-block { margin-bottom: 28px; }
.art-h2 {
  font-family: var(--font-sans);
  font-size: clamp(20px, 2.4vw, 24px);
  font-weight: 600; line-height: 1.4;
  margin: 0 0 12px;
  color: var(--text);
  letter-spacing: -.005em;
}
.article p { font-size: 16px; line-height: 1.6; margin: 0 0 10px; color: var(--text); }
.article p strong { color: var(--text); font-weight: 700; }
.art-list { padding-left: 22px; margin: 8px 0 0; }
.art-list li { font-size: 16px; line-height: 1.6; margin-bottom: 6px; color: var(--text); }

.rating-cards {
  display: grid; gap: 16px; margin-top: 8px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
@media (max-width: 720px) { .rating-cards { grid-template-columns: 1fr; } }
.rating-card {
  background: #EEF7FF;
  border-radius: var(--radius);
  padding: 20px 18px;
  display: flex; flex-direction: column; gap: 8px;
}
.rating-card strong { font-size: 17px; font-weight: 700; color: var(--text); }
.rating-card p { margin: 0; font-size: 14.5px; line-height: 1.5; color: var(--text); }

.art-type {
  padding: 12px 0;
}
.art-type p { margin: 0; }

/* ─── LEGAL ─── */
.legal-band { background: var(--bg-soft); padding: 40px 0; }
.legal { max-width: 880px; }
.legal p { font-size: 12.5px; line-height: 1.6; color: var(--text-muted); margin: 0 0 10px; }
.legal p:last-child { margin-bottom: 0; }

/* ─── FOOTER ─── */
.site-footer {
  border-top: 1px solid var(--border);
  background: #fff;
  padding: 24px 0;
}
.foot-row {
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px;
  font-size: 13px; color: var(--text-muted);
}
.foot-links { display: inline-flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.foot-links a { color: var(--text-muted); font-weight: 500; }
.foot-links a:hover { color: var(--primary); text-decoration: underline; }
.foot-links span { color: var(--text-subtle); }
@media (max-width: 640px) { .foot-row { flex-direction: column; align-items: flex-start; } }

/* ─── POLICY PAGES ─── */
.policy { max-width: 760px; margin: 0 auto; padding: 56px 24px 80px; }
.policy h1 {
  font-family: var(--font-serif); font-weight: 600;
  font-size: clamp(32px, 4.4vw, 44px); letter-spacing: -.015em;
  margin: 0 0 12px; line-height: 1.1;
}
.policy .updated {
  font-size: 13px; color: var(--text-subtle); margin: 0 0 32px;
  font-weight: 500; letter-spacing: .02em;
}
.policy h2 {
  font-family: var(--font-sans); font-weight: 600;
  font-size: 20px; line-height: 1.4;
  margin: 36px 0 12px; color: var(--text);
  letter-spacing: -.005em;
}
.policy h3 {
  font-size: 16px; font-weight: 700; line-height: 1.4;
  margin: 20px 0 8px; color: var(--text);
}
.policy p { font-size: 16px; line-height: 1.65; margin: 0 0 14px; color: var(--text); }
.policy ul { padding-left: 22px; margin: 8px 0 16px; }
.policy li { font-size: 16px; line-height: 1.6; margin-bottom: 6px; }
.policy a { color: var(--accent); }
.policy a:hover { text-decoration: underline; }
.policy .back {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 14px; font-weight: 500; color: var(--text-muted);
  margin-bottom: 28px;
}
.policy .back:hover { color: var(--primary); text-decoration: none; }
.policy .back svg { transition: transform 160ms var(--ease); }
.policy .back:hover svg { transform: translateX(-3px); }
