/* ============================================================
   PigEars.company — Shared asset styles (articles + legal)
   Saffron design system tokens are declared inline here so
   article pages don't need a separate saffron.css import.
   ============================================================ */

@import url("https://fonts.googleapis.com/css2?family=Newsreader:opsz,wght@6..72,400;6..72,500;6..72,600;6..72,700&family=DM+Sans:opsz,wght@9..40,400;9..40,500;9..40,600;9..40,700&family=JetBrains+Mono:wght@400;500;600&display=swap");

:root {
  --saffron-300: #FFE88A;
  --saffron-400: #FFDD63;
  --saffron-500: #FFD23F;
  --saffron-600: #F5C518;
  --saffron-700: #D9A800;

  --ink-900: #1B2235;
  --ink-800: #232B40;
  --ink-700: #3A4358;
  --ink-500: #6B7387;
  --ink-300: #B7BCC9;
  --ink-100: #E4E6EC;

  --cream-50:  #FAF6EC;
  --cream-100: #F3EEDD;
  --cream-200: #EAE3CB;

  --mint-100: #EAF3EA;
  --mint-200: #DDEDDE;
  --mint-600: #5A9466;

  --charcoal-800: #22303C;

  --bg: var(--cream-50);
  --fg: var(--ink-900);

  --border: rgba(27,34,53,0.08);
  --border-strong: rgba(27,34,53,0.16);

  --font-display: "Newsreader","Cormorant Garamond",Georgia,serif;
  --font-sans: "DM Sans",ui-sans-serif,system-ui,sans-serif;
  --font-mono: "JetBrains Mono",ui-monospace,Menlo,monospace;

  --radius-md: 14px;
  --radius-xl: 28px;
  --radius-pill: 999px;

  --shadow-sm: 0 1px 2px rgba(27,34,53,0.06),0 1px 1px rgba(27,34,53,0.04);
  --shadow-md: 0 6px 16px rgba(27,34,53,0.08),0 2px 4px rgba(27,34,53,0.05);
  --shadow-yellow: 0 10px 28px rgba(255,210,63,0.45);

  --ease: cubic-bezier(0.2,0.7,0.2,1);
  --dur-micro: 150ms;
  --dur-base: 220ms;
}

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

html { scroll-behavior: smooth; }
body {
  font-family: var(--font-sans);
  font-size: 18px;
  line-height: 1.55;
  color: var(--ink-900);
  background: var(--cream-50);
  -webkit-font-smoothing: antialiased;
}

/* ─── Shared layout ─── */
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 32px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

/* ─── Nav (pill style) ─── */
.site-header {
  position: sticky; top: 16px; z-index: 900;
  display: flex; justify-content: center;
  padding: 0 16px; pointer-events: none;
}
.nav-wrap {
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-md);
  padding: 8px 8px 8px 24px;
  display: flex; align-items: center; gap: 24px;
  width: 100%; max-width: 1200px;
  pointer-events: all;
}
.nav-brand {
  font-family: var(--font-display);
  font-size: 22px; font-weight: 600; color: var(--ink-900);
  text-decoration: none; white-space: nowrap; flex-shrink: 0;
}
.nav-links { display: flex; gap: 28px; list-style: none; flex: 1; justify-content: center; }
.nav-links a {
  font-size: 15px; font-weight: 500; color: var(--ink-700);
  text-decoration: none; transition: color var(--dur-base) var(--ease);
}
.nav-links a:hover { color: var(--ink-900); }
.nav-shop-btn {
  flex-shrink: 0; font-size: 15px;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--ink-900); color: var(--cream-50);
  font-family: var(--font-sans); font-weight: 600;
  padding: 12px 22px; border-radius: var(--radius-pill);
  text-decoration: none; transition: background var(--dur-micro);
}
.nav-shop-btn:hover { background: var(--ink-700); }
.nav-burger {
  display: none; background: var(--ink-900); border: none; cursor: pointer;
  width: 44px; height: 44px; border-radius: 14px;
  align-items: center; justify-content: center;
  flex-direction: column; gap: 5px; flex-shrink: 0;
}
.nav-burger span {
  display: block; width: 18px; height: 2px; background: var(--cream-50);
  border-radius: 2px; transition: transform var(--dur-base) var(--ease), opacity var(--dur-base) var(--ease);
}
.nav-burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ─── Mobile overlay ─── */
.mobile-overlay {
  display: none; position: fixed; inset: 0; z-index: 9999;
  background: rgba(27,34,53,0.96); backdrop-filter: blur(8px);
  flex-direction: column; align-items: center; justify-content: center;
  opacity: 0; transition: opacity var(--dur-base);
}
.mobile-overlay.open { display: flex; opacity: 1; }
.mobile-close {
  position: absolute; top: 20px; right: 20px; background: none; border: none;
  cursor: pointer; padding: 10px; display: flex; align-items: center; justify-content: center;
  min-width: 44px; min-height: 44px;
}
.mobile-overlay nav { display: flex; flex-direction: column; align-items: center; }
.mobile-overlay ul { list-style: none; text-align: center; margin-bottom: 32px; }
.mobile-overlay ul li { margin: 14px 0; }
.mobile-overlay ul li a {
  font-family: var(--font-display); font-size: 28px; font-weight: 500;
  color: var(--cream-50); text-decoration: none; transition: color var(--dur-base);
}
.mobile-overlay ul li a:hover { color: var(--saffron-500); }
.mobile-shop-btn {
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--saffron-500); color: var(--ink-900);
  font-family: var(--font-sans); font-weight: 700; font-size: 17px;
  padding: 16px 36px; border-radius: var(--radius-pill); text-decoration: none;
}

/* ─── Article hero ─── */
.post-header {
  background: radial-gradient(ellipse 80% 120% at 50% 0%, rgba(255,210,63,.28), transparent 70%),
              var(--cream-50);
  padding: 80px 24px 60px;
  text-align: center;
}
.post-header .breadcrumb {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  font-size: 13px; color: var(--ink-500); margin-bottom: 20px;
  font-family: var(--font-sans);
}
.post-header .breadcrumb a { color: var(--ink-500); text-decoration: none; transition: color var(--dur-base); }
.post-header .breadcrumb a:hover { color: var(--ink-900); }
.post-header .breadcrumb-sep { color: var(--ink-300); }
.post-header .post-cat {
  display: inline-block;
  background: var(--cream-100); border: 1px solid var(--border);
  color: var(--ink-700); font-size: 13px; font-weight: 600;
  letter-spacing: .10em; text-transform: uppercase;
  padding: 4px 14px; border-radius: var(--radius-pill);
  margin-bottom: 20px;
}
.post-header h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 500; letter-spacing: -0.02em;
  color: var(--ink-900);
  max-width: 800px; margin: 0 auto 16px;
  line-height: 1.12; text-wrap: balance;
}
.post-header .post-meta {
  font-family: var(--font-mono);
  font-size: 14px; color: var(--ink-500);
}

/* ─── Article body ─── */
.post-body {
  max-width: 800px; margin: 0 auto;
  padding: 60px 24px 80px;
}
.post-body h1 { display: none; } /* hide duplicate h1 if present in generated content */
.post-body h2 {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 500; letter-spacing: -0.02em;
  color: var(--ink-900); margin: 48px 0 16px;
  padding-top: 0.5em; border-top: 1px solid var(--border);
}
.post-body h2:first-child { border-top: none; padding-top: 0; margin-top: 0; }
.post-body h3 {
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 2vw, 1.5rem); font-weight: 500;
  color: var(--ink-900); margin: 32px 0 12px; letter-spacing: -0.01em;
}
.post-body h4 {
  font-family: var(--font-sans); font-size: 13px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .08em;
  color: var(--ink-700); margin: 24px 0 8px;
}
.post-body p { color: var(--ink-700); margin-bottom: 20px; font-size: 17px; line-height: 1.7; }
.post-body strong { color: var(--ink-900); font-weight: 600; }
.post-body a { color: var(--ink-900); border-bottom: 2px solid var(--saffron-500); text-decoration: none; }
.post-body a:hover { background: rgba(255,210,63,.12); }
.post-body ul, .post-body ol { margin: 0 0 20px 28px; }
.post-body li { margin-bottom: 8px; color: var(--ink-700); font-size: 17px; }
.post-body table { width: 100%; border-collapse: collapse; margin: 24px 0; font-size: 15px; }
.post-body th { background: var(--ink-900); color: var(--cream-50); padding: 10px 14px; text-align: left; font-family: var(--font-sans); }
.post-body td { padding: 10px 14px; border-bottom: 1px solid var(--border); color: var(--ink-700); }
.post-body tr:nth-child(even) td { background: var(--cream-100); }

/* ─── Post footer CTA ─── */
.post-cta {
  background: var(--ink-900);
  text-align: center; padding: 60px 24px;
}
.post-cta h2 {
  font-family: var(--font-display); font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 500; letter-spacing: -0.02em; color: var(--cream-50);
  margin-bottom: 12px;
}
.post-cta p { color: rgba(250,246,236,.75); margin-bottom: 28px; font-size: 17px; }
.btn-accent {
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--saffron-500); color: var(--ink-900);
  font-family: var(--font-sans); font-weight: 700; font-size: 16px;
  padding: 14px 32px; border-radius: var(--radius-pill);
  text-decoration: none; box-shadow: var(--shadow-yellow);
  transition: background var(--dur-micro), transform 80ms var(--ease);
}
.btn-accent:hover { background: var(--saffron-600); transform: translateY(-2px); }

/* ─── Footer ─── */
.site-footer {
  background: var(--charcoal-800);
  padding: 64px 24px 32px;
}
.footer-inner {
  max-width: 1200px; margin: 0 auto;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 36px; margin-bottom: 40px;
}
.footer-col h4 {
  font-family: var(--font-sans); font-size: 13px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .12em;
  color: var(--saffron-500); margin-bottom: 14px;
}
.footer-col a {
  display: block; color: rgba(250,246,236,.85); text-decoration: none;
  font-size: 14px; margin-bottom: 8px; transition: color var(--dur-base);
}
.footer-col a:hover { color: var(--cream-50); }
.footer-col p { color: rgba(250,246,236,.65); font-size: 13px; line-height: 1.6; margin-bottom: 6px; }
.footer-wordmark {
  font-family: var(--font-display); font-size: 20px; font-weight: 600;
  color: var(--cream-50); margin-bottom: 12px;
}
.footer-bottom {
  max-width: 1200px; margin: 0 auto;
  border-top: 1px solid rgba(255,255,255,.10); padding-top: 24px;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 12px;
  color: rgba(250,246,236,.45); font-size: 13px;
}
.footer-bottom a { color: rgba(250,246,236,.4); text-decoration: none; }
.footer-bottom a:hover { color: var(--cream-50); }

/* ─── Legal page ─── */
.legal-body { max-width: 900px; margin: 0 auto; padding: 60px 24px 80px; }
.legal-body h2 {
  font-family: var(--font-display); font-size: clamp(1.4rem, 2.5vw, 1.8rem);
  font-weight: 500; color: var(--ink-900); margin: 40px 0 14px;
  padding-bottom: 8px; border-bottom: 1px solid var(--border);
}
.legal-body h3 { font-family: var(--font-display); font-size: 1.1rem; color: var(--ink-700); margin: 24px 0 10px; }
.legal-body p { margin-bottom: 16px; color: var(--ink-700); font-size: 17px; }
.legal-body ul { margin: 0 0 16px 28px; }
.legal-body li { margin-bottom: 6px; color: var(--ink-700); }

/* ─── Responsive ─── */
@media (max-width: 880px) {
  .nav-links, .nav-shop-btn { display: none; }
  .nav-burger { display: flex; }
  .nav-wrap { padding: 8px 8px 8px 18px; gap: 12px; }
  .nav-brand { font-size: 18px; }
}
@media (max-width: 720px) {
  .wrap { padding: 0 16px; }
  .post-header { padding: 60px 16px 40px; }
  .post-body, .legal-body { padding: 40px 16px 60px; }
  .site-header { padding: 0 8px; }
}
@media (max-width: 420px) {
  .nav-brand { font-size: 16px; }
}
