/* while.chat — Editorial Blog Stylesheet */

:root {
  --espresso: #1a1410;
  --dark-roast: #2c2218;
  --medium-roast: #4a3728;
  --crema: #c4a882;
  --latte: #e8ddd0;
  --oat-milk: #f4efe8;
  --foam: #faf8f5;
  --white: #fff;
  --accent: #8b6914;
  --text: #2c2218;
  --text-light: #6b5b4e;
  --border: #e0d5c8;
  --r: 6px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; font-size: 18px; }

body {
  font-family: 'Source Serif 4', 'Georgia', serif;
  background: var(--foam);
  color: var(--text);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

/* ═══ NAV ═══ */
.nav {
  padding: 20px 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border);
  background: var(--foam);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(12px);
}
.nav-brand {
  font-family: 'DM Serif Display', serif;
  font-size: 1.3rem;
  color: var(--espresso);
  text-decoration: none;
  letter-spacing: 0.5px;
}
.nav-brand span { color: var(--crema); }
.nav-links { display: flex; gap: 28px; align-items: center; }
.nav-links a {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.78rem;
  color: var(--text-light);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  transition: color 0.3s;
}
.nav-links a:hover { color: var(--espresso); }

/* ═══ HERO ═══ */
.hero {
  padding: 100px 40px 80px;
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
}
.hero-badge {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.65rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--crema);
  margin-bottom: 24px;
}
.hero h1 {
  font-family: 'DM Serif Display', serif;
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  font-weight: 400;
  line-height: 1.2;
  color: var(--espresso);
  margin-bottom: 20px;
}
.hero p {
  font-size: 1.05rem;
  color: var(--text-light);
  max-width: 520px;
  margin: 0 auto;
  line-height: 1.8;
}

/* ═══ CATEGORY PILLS ═══ */
.categories {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
  padding: 0 40px 60px;
  max-width: 800px;
  margin: 0 auto;
}
.cat-pill {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.72rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 6px 16px;
  border: 1px solid var(--border);
  border-radius: 100px;
  color: var(--text-light);
  text-decoration: none;
  transition: all 0.3s;
}
.cat-pill:hover, .cat-pill.active {
  background: var(--espresso);
  color: var(--foam);
  border-color: var(--espresso);
}

/* ═══ ARTICLE GRID ═══ */
.articles {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 40px 80px;
  display: flex;
  flex-direction: column;
  gap: 48px;
}
.article-card {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  padding-bottom: 48px;
  border-bottom: 1px solid var(--border);
  text-decoration: none;
  color: inherit;
  transition: transform 0.3s cubic-bezier(0.22,1,0.36,1);
}
.article-card:hover { transform: translateY(-3px); }
.article-meta {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.7rem;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--crema);
  display: flex;
  gap: 16px;
  align-items: center;
}
.article-meta .dot { width: 3px; height: 3px; background: var(--crema); border-radius: 50%; }
.article-card h2 {
  font-family: 'DM Serif Display', serif;
  font-size: 1.6rem;
  font-weight: 400;
  line-height: 1.3;
  color: var(--espresso);
}
.article-card .excerpt {
  font-size: 0.95rem;
  color: var(--text-light);
  line-height: 1.7;
}

/* ═══ ARTICLE PAGE ═══ */
.article-header {
  max-width: 720px;
  margin: 0 auto;
  padding: 80px 40px 40px;
  text-align: center;
}
.article-header .cat {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.65rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--crema);
  margin-bottom: 20px;
}
.article-header h1 {
  font-family: 'DM Serif Display', serif;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 400;
  line-height: 1.25;
  color: var(--espresso);
  margin-bottom: 20px;
}
.article-header .meta {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.78rem;
  color: var(--text-light);
  letter-spacing: 0.5px;
}

.article-content {
  max-width: 680px;
  margin: 0 auto;
  padding: 40px 40px 100px;
}
.article-content h2 {
  font-family: 'DM Serif Display', serif;
  font-size: 1.5rem;
  font-weight: 400;
  color: var(--espresso);
  margin: 48px 0 16px;
}
.article-content h3 {
  font-family: 'DM Sans', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  color: var(--medium-roast);
  margin: 32px 0 12px;
}
.article-content h4 {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--medium-roast);
  margin: 24px 0 8px;
}
.article-content p {
  margin-bottom: 20px;
  font-size: 1rem;
  line-height: 1.8;
}
.article-content em { font-style: italic; }
.article-content strong { font-weight: 700; color: var(--espresso); }
.article-content ul, .article-content ol {
  margin: 16px 0 20px 24px;
}
.article-content li {
  margin-bottom: 8px;
  line-height: 1.7;
}
.article-content blockquote {
  border-left: 3px solid var(--crema);
  padding: 12px 24px;
  margin: 24px 0;
  font-style: italic;
  color: var(--text-light);
  background: var(--oat-milk);
  border-radius: 0 var(--r) var(--r) 0;
}
.article-content .highlight-box {
  background: var(--oat-milk);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 24px;
  margin: 24px 0;
}
.article-content .sources {
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
  font-size: 0.85rem;
  color: var(--text-light);
}
.article-content .sources h3 { margin-top: 0; }

/* ═══ BACK LINK ═══ */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.78rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-light);
  text-decoration: none;
  padding: 40px 40px 0;
  max-width: 720px;
  margin: 0 auto;
  display: block;
  transition: color 0.3s;
}
.back-link:hover { color: var(--espresso); }

/* ═══ FOOTER ═══ */
.footer {
  padding: 48px 40px;
  border-top: 1px solid var(--border);
  text-align: center;
}
.footer-brand {
  font-family: 'DM Serif Display', serif;
  font-size: 1.1rem;
  color: var(--espresso);
  margin-bottom: 12px;
}
.footer p {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.75rem;
  color: var(--text-light);
  letter-spacing: 0.5px;
}
.footer-links {
  margin-top: 16px;
  display: flex;
  gap: 24px;
  justify-content: center;
}
.footer-links a {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.72rem;
  color: var(--text-light);
  text-decoration: none;
  letter-spacing: 0.5px;
  transition: color 0.3s;
}
.footer-links a:hover { color: var(--espresso); }

/* ═══ RESPONSIVE ═══ */
@media (max-width: 640px) {
  html { font-size: 16px; }
  .nav { padding: 16px 20px; }
  .nav-links { gap: 16px; }
  .hero { padding: 60px 20px 40px; }
  .categories { padding: 0 20px 40px; }
  .articles { padding: 0 20px 60px; }
  .article-header { padding: 60px 20px 30px; }
  .article-content { padding: 30px 20px 80px; }
  .back-link { padding: 30px 20px 0; }
}
