/* ============================================================
   GoodPoo.co — Stylesheet
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;600;700&family=Inter:wght@300;400;500;600&display=swap');

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

:root {
  --green-dark:   #2d6a4f;
  --green-mid:    #40916c;
  --green-light:  #74c69d;
  --green-pale:   #d8f3dc;
  --amber:        #e07b39;
  --amber-light:  #f4a261;
  --cream:        #faf8f4;
  --sand:         #f0ebe0;
  --charcoal:     #2b2b2b;
  --grey:         #6b7280;
  --grey-light:   #e5e7eb;
  --white:        #ffffff;

  --font-heading: 'Playfair Display', Georgia, serif;
  --font-body:    'Inter', system-ui, sans-serif;

  --radius:       12px;
  --radius-sm:    6px;
  --shadow:       0 4px 20px rgba(0,0,0,.08);
  --shadow-hover: 0 8px 32px rgba(0,0,0,.14);
  --transition:   0.22s ease;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--cream);
  color: var(--charcoal);
  line-height: 1.7;
  font-size: 16px;
}

img { max-width: 100%; height: auto; display: block; }
a   { color: var(--green-dark); text-decoration: none; }
a:hover { color: var(--amber); }

/* === Utility === */
.container { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.section    { padding: 80px 0; }
.section--alt { background: var(--sand); }
.text-center { text-align: center; }
.tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 20px;
  background: var(--green-pale);
  color: var(--green-dark);
}

/* === Header / Nav === */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--white);
  border-bottom: 1px solid var(--grey-light);
  box-shadow: 0 2px 12px rgba(0,0,0,.05);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}

.nav__logo {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--green-dark);
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav__logo span { color: var(--amber); }

.nav__links {
  display: flex;
  gap: 32px;
  list-style: none;
}

.nav__links a {
  font-size: .92rem;
  font-weight: 500;
  color: var(--charcoal);
  transition: color var(--transition);
}
.nav__links a:hover { color: var(--green-mid); }
.nav__links a.active { color: var(--green-dark); font-weight: 600; }

.nav__cta {
  background: var(--green-dark);
  color: var(--white) !important;
  padding: 8px 20px;
  border-radius: 24px;
  transition: background var(--transition) !important;
}
.nav__cta:hover { background: var(--green-mid) !important; color: var(--white) !important; }

.nav__hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
}
.nav__hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--charcoal);
  border-radius: 2px;
  transition: var(--transition);
}

/* === Hero (Home) === */
.hero {
  background: linear-gradient(135deg, var(--green-dark) 0%, var(--green-mid) 60%, var(--green-light) 100%);
  color: var(--white);
  padding: 100px 0 80px;
  overflow: hidden;
  position: relative;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.04'%3E%3Ccircle cx='30' cy='30' r='20'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.hero__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  position: relative;
}

.hero__eyebrow {
  font-size: .85rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--green-pale);
  margin-bottom: 16px;
}

.hero__title {
  font-family: var(--font-heading);
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  line-height: 1.2;
  margin-bottom: 20px;
}

.hero__title em {
  font-style: normal;
  color: var(--amber-light);
}

.hero__desc {
  font-size: 1.1rem;
  line-height: 1.8;
  color: rgba(255,255,255,.88);
  margin-bottom: 36px;
  max-width: 520px;
}

.hero__actions { display: flex; gap: 16px; flex-wrap: wrap; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 32px;
  font-size: .95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  border: 2px solid transparent;
  text-decoration: none;
}

.btn--primary {
  background: var(--amber);
  color: var(--white);
}
.btn--primary:hover {
  background: var(--amber-light);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(224,123,57,.4);
}

.btn--outline {
  background: transparent;
  border-color: rgba(255,255,255,.5);
  color: var(--white);
}
.btn--outline:hover {
  background: rgba(255,255,255,.12);
  color: var(--white);
  border-color: var(--white);
}

.hero__image {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-hover);
  aspect-ratio: 4/3;
  background: var(--green-pale);
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero__image--placeholder {
  font-size: 4rem;
  opacity: .3;
}

/* === Stats Bar === */
.stats-bar {
  background: var(--white);
  border-bottom: 1px solid var(--grey-light);
  padding: 24px 0;
}

.stats-bar__inner {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  text-align: center;
}

.stat__number {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--green-dark);
  display: block;
}

.stat__label {
  font-size: .82rem;
  color: var(--grey);
  margin-top: 2px;
}

/* === Section Headings === */
.section-heading {
  margin-bottom: 48px;
}

.section-heading__sub {
  font-size: .85rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--green-mid);
  margin-bottom: 12px;
  display: block;
}

.section-heading__title {
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  line-height: 1.25;
  color: var(--charcoal);
  margin-bottom: 16px;
}

.section-heading__desc {
  font-size: 1.05rem;
  color: var(--grey);
  max-width: 600px;
}

/* === Article Cards === */
.articles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.articles-grid--2col { grid-template-columns: repeat(2, 1fr); }
.articles-grid--4col { grid-template-columns: repeat(4, 1fr); }

.card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform var(--transition), box-shadow var(--transition);
  display: flex;
  flex-direction: column;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}

.card__image {
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--green-pale);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}

.card:hover .card__image img { transform: scale(1.04); }

.card__image--placeholder {
  font-size: 2.5rem;
  opacity: .35;
}

.card__body {
  padding: 24px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.card__meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
  font-size: .82rem;
  color: var(--grey);
}

.card__title {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--charcoal);
  margin-bottom: 10px;
  line-height: 1.35;
}

.card__excerpt {
  font-size: .9rem;
  color: var(--grey);
  line-height: 1.65;
  flex: 1;
  margin-bottom: 20px;
}

.card__link {
  font-size: .88rem;
  font-weight: 600;
  color: var(--green-dark);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: auto;
  transition: gap var(--transition), color var(--transition);
}

.card:hover .card__link { gap: 10px; color: var(--amber); }

/* === Featured Article (first card) === */
.card--featured {
  grid-column: span 2;
  flex-direction: row;
}

.card--featured .card__image {
  width: 45%;
  min-height: 280px;
  aspect-ratio: unset;
  flex-shrink: 0;
  border-radius: 0;
}

.card--featured .card__title { font-size: 1.5rem; }

/* === Topics Strip === */
.topics-strip {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

.topic-pill {
  padding: 8px 18px;
  border-radius: 20px;
  border: 1.5px solid var(--grey-light);
  font-size: .85rem;
  font-weight: 500;
  color: var(--charcoal);
  cursor: pointer;
  transition: all var(--transition);
  background: var(--white);
}

.topic-pill:hover, .topic-pill.active {
  background: var(--green-dark);
  border-color: var(--green-dark);
  color: var(--white);
}

/* === Newsletter Banner === */
.newsletter {
  background: linear-gradient(135deg, var(--green-dark), var(--green-mid));
  color: var(--white);
  border-radius: var(--radius);
  padding: 60px;
  text-align: center;
  margin: 0 auto;
}

.newsletter__title {
  font-family: var(--font-heading);
  font-size: 2rem;
  margin-bottom: 12px;
}

.newsletter__desc {
  color: rgba(255,255,255,.85);
  margin-bottom: 32px;
  font-size: 1.05rem;
}

.newsletter__form {
  display: flex;
  gap: 12px;
  max-width: 480px;
  margin: 0 auto;
}

.newsletter__input {
  flex: 1;
  padding: 14px 20px;
  border-radius: 32px;
  border: none;
  font-size: .95rem;
  outline: none;
  font-family: var(--font-body);
}

.newsletter__input:focus { box-shadow: 0 0 0 3px rgba(255,255,255,.3); }

/* === Article Page === */
.article-hero {
  background: linear-gradient(135deg, var(--green-dark) 0%, var(--green-mid) 100%);
  color: var(--white);
  padding: 72px 0 60px;
}

.article-hero__breadcrumb {
  font-size: .85rem;
  color: rgba(255,255,255,.7);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.article-hero__breadcrumb a { color: rgba(255,255,255,.85); }
.article-hero__breadcrumb a:hover { color: var(--white); }

.article-hero__tag { margin-bottom: 16px; }

.article-hero__title {
  font-family: var(--font-heading);
  font-size: clamp(1.9rem, 3.5vw, 3rem);
  line-height: 1.2;
  margin-bottom: 20px;
  max-width: 800px;
}

.article-hero__meta {
  display: flex;
  align-items: center;
  gap: 20px;
  font-size: .88rem;
  color: rgba(255,255,255,.75);
}

.article-hero__meta span { display: flex; align-items: center; gap: 6px; }

.article-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 60px;
  padding: 64px 0 80px;
  align-items: start;
}

.article-image {
  width: 100%;
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 48px;
  aspect-ratio: 16/7;
  background: var(--green-pale);
  display: flex;
  align-items: center;
  justify-content: center;
}

.article-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.article-image--placeholder { font-size: 3rem; opacity: .3; }

/* Prose */
.prose { color: var(--charcoal); }
.prose h2 {
  font-family: var(--font-heading);
  font-size: 1.65rem;
  color: var(--green-dark);
  margin: 44px 0 16px;
  padding-top: 8px;
  border-top: 2px solid var(--green-pale);
}
.prose h3 {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  color: var(--charcoal);
  margin: 28px 0 10px;
}
.prose p { margin-bottom: 20px; line-height: 1.85; }
.prose ul, .prose ol { margin: 0 0 20px 24px; }
.prose li { margin-bottom: 8px; line-height: 1.75; }
.prose strong { font-weight: 600; color: var(--green-dark); }
.prose a { color: var(--green-mid); text-decoration: underline; }
.prose a:hover { color: var(--amber); }

.prose .callout {
  background: var(--green-pale);
  border-left: 4px solid var(--green-mid);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 20px 24px;
  margin: 28px 0;
}
.prose .callout p { margin-bottom: 0; }
.prose .callout strong { color: var(--green-dark); }

/* Sidebar */
.sidebar { position: sticky; top: 96px; }

.sidebar-widget {
  background: var(--white);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
  margin-bottom: 28px;
}

.sidebar-widget__title {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  color: var(--charcoal);
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--green-pale);
}

.sidebar-article {
  display: flex;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--grey-light);
}
.sidebar-article:last-child { border-bottom: none; }

.sidebar-article__image {
  width: 60px;
  height: 60px;
  border-radius: var(--radius-sm);
  background: var(--green-pale);
  flex-shrink: 0;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
}
.sidebar-article__image img { width: 100%; height: 100%; object-fit: cover; }

.sidebar-article__title {
  font-size: .88rem;
  font-weight: 600;
  line-height: 1.4;
  color: var(--charcoal);
  margin-bottom: 4px;
}
.sidebar-article__title a { color: inherit; }
.sidebar-article__title a:hover { color: var(--green-mid); }

.sidebar-article__meta { font-size: .78rem; color: var(--grey); }

.toc-list { list-style: none; margin: 0; padding: 0; }
.toc-list li { border-bottom: 1px solid var(--grey-light); }
.toc-list li:last-child { border-bottom: none; }
.toc-list a {
  display: block;
  padding: 8px 0;
  font-size: .88rem;
  color: var(--grey);
  transition: color var(--transition), padding-left var(--transition);
}
.toc-list a:hover {
  color: var(--green-dark);
  padding-left: 6px;
}

/* === Footer === */
.site-footer {
  background: var(--charcoal);
  color: rgba(255,255,255,.75);
  padding: 64px 0 32px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}

.footer-brand__logo {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 16px;
  display: block;
}
.footer-brand__logo span { color: var(--amber-light); }

.footer-brand__desc {
  font-size: .9rem;
  line-height: 1.7;
  margin-bottom: 24px;
  max-width: 280px;
}

.footer-col__title {
  font-size: .85rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 20px;
}

.footer-links { list-style: none; }
.footer-links li { margin-bottom: 10px; }
.footer-links a {
  font-size: .9rem;
  color: rgba(255,255,255,.65);
  transition: color var(--transition);
}
.footer-links a:hover { color: var(--amber-light); }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.1);
  padding-top: 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: .85rem;
  color: rgba(255,255,255,.45);
}

.disclaimer {
  background: rgba(255,255,255,.05);
  border-radius: var(--radius-sm);
  padding: 20px 24px;
  font-size: .82rem;
  color: rgba(255,255,255,.5);
  line-height: 1.6;
  margin-bottom: 32px;
}

/* === Responsive === */
@media (max-width: 1024px) {
  .articles-grid        { grid-template-columns: repeat(2, 1fr); }
  .articles-grid--4col  { grid-template-columns: repeat(2, 1fr); }
  .card--featured       { grid-column: span 2; }
  .footer-grid          { grid-template-columns: 1fr 1fr; gap: 32px; }
  .stats-bar__inner     { grid-template-columns: repeat(2, 1fr); }
  .article-layout       { grid-template-columns: 1fr; gap: 40px; }
  .sidebar              { position: static; }
}

@media (max-width: 768px) {
  .hero__inner          { grid-template-columns: 1fr; gap: 36px; }
  .hero__image          { display: none; }
  .nav__links           { display: none; }
  .nav__hamburger       { display: flex; }
  .articles-grid        { grid-template-columns: 1fr; }
  .articles-grid--2col  { grid-template-columns: 1fr; }
  .card--featured       { flex-direction: column; grid-column: span 1; }
  .card--featured .card__image { width: 100%; min-height: 200px; }
  .newsletter           { padding: 36px 24px; }
  .newsletter__form     { flex-direction: column; }
  .footer-grid          { grid-template-columns: 1fr; }
  .footer-bottom        { flex-direction: column; gap: 12px; text-align: center; }
  .section              { padding: 56px 0; }
  .article-hero         { padding: 48px 0 40px; }
  .article-image        { aspect-ratio: 16/9; }
}
