/* Enviro Daily — Ghost theme. Brand: Outfit; charcoal #333B41, teal #2E8F8C. */
:root {
  --charcoal: #333B41; --slate: #4A565B; --teal: #2E8F8C; --teal-dark: #23706D; --teal-light: #6FD0CB;
  --mist: #EEF1F1; --line: #DDE2E4; --white: #FFFFFF; --alert: #C23B3E;
  --lime: #C8DA2B; --green: #3E8F4E; --blue: #3F5E9A;
  --gradient: linear-gradient(90deg, var(--lime), var(--green) 55%, var(--blue));
  --font: var(--gh-font-body, 'Outfit', system-ui, -apple-system, 'Segoe UI', sans-serif);
  --font-heading: var(--gh-font-heading, 'Outfit', system-ui, sans-serif);
  --radius: 8px; --radius-lg: 16px; --wrap: 1180px;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--white); color: var(--charcoal); font-family: var(--font); font-size: 17px; line-height: 1.6; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--teal-dark); }
a:hover { color: var(--charcoal); }
h1, h2, h3, h4 { line-height: 1.15; margin: 0; font-family: var(--font-heading); }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.narrow { max-width: 760px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -9999px; top: 8px; background: var(--charcoal); color: #fff; padding: 8px 14px; z-index: 10; }
.skip-link:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--teal); outline-offset: 2px; }

/* Labels and buttons */
.label { display: inline-block; font-size: 12px; font-weight: 600; letter-spacing: 1.8px; text-transform: uppercase; color: var(--teal-dark); text-decoration: none; }
.label-alert { background: var(--alert); color: #fff; padding: 3px 9px; border-radius: 4px; }
.label-teal { color: var(--teal-dark); }
.via { font-size: 12px; font-weight: 500; color: var(--slate); border: 1px solid var(--line); border-radius: 20px; padding: 0 8px; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 20px; border-radius: var(--radius); border: 0; font: 600 15px var(--font); text-decoration: none; cursor: pointer; }
.btn-primary { background: var(--teal-dark); color: #fff; }
.btn-primary:hover { background: var(--charcoal); color: #fff; }
.btn-dark { background: var(--charcoal); color: #fff; }
.btn-dark:hover { background: var(--teal-dark); color: #fff; }

/* Header */
.topbar { background: var(--mist); border-bottom: 1px solid var(--line); font-size: 13px; }
.topbar-inner { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 6px 20px; padding-top: 7px; padding-bottom: 7px; }
.topbar-note { color: var(--slate); }
.topbar-links { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.topbar-links a { color: var(--charcoal); text-decoration: none; }
.topbar-links .topbar-cta { font-weight: 700; color: var(--teal-dark); }
.site-header { border-bottom: 1px solid var(--line); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 20px; padding-bottom: 18px; }
.site-logo img { width: 280px; max-width: 60vw; }
.header-search { margin: 0; }
.search-btn { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px; border: 1px solid var(--line); border-radius: 22px; background: #fff; color: var(--charcoal); font: 500 15px var(--font); cursor: pointer; }
.nav-toggle { display: none; min-height: 44px; padding: 0 16px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; font: 600 15px var(--font); color: var(--charcoal); }
.site-nav { border-top: 1px solid var(--line); }
.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0 24px; }
.site-nav a { display: block; padding: 12px 0; font-weight: 600; font-size: 15px; color: var(--charcoal); text-decoration: none; border-bottom: 3px solid transparent; }
.site-nav a:hover, .site-nav .nav-current a { border-bottom-color: var(--teal); }
.breaking { background: #FBECEC; border-bottom: 1px solid #F2D0D0; }
.breaking-inner { display: flex; gap: 12px; align-items: center; padding-top: 9px; padding-bottom: 9px; font-weight: 600; }
.breaking-inner a { color: var(--charcoal); }

/* Welcome */
.welcome { background: var(--charcoal); color: #fff; }
.welcome .wrap { padding-top: 36px; padding-bottom: 36px; position: relative; }
.welcome .wrap::after { content: ""; display: block; width: 140px; height: 6px; border-radius: 3px; background: var(--gradient); margin-top: 22px; }
.welcome h1 { font-size: 34px; font-weight: 800; }
.welcome h1 span { color: var(--teal-light); }
.welcome p { margin: 8px 0 0; max-width: 760px; color: #D9DEE0; font-size: 18px; }

/* Layout */
.page-body { padding-top: 36px; padding-bottom: 56px; display: flex; flex-direction: column; gap: 40px; }
.columns { display: flex; flex-wrap: wrap; gap: 40px; align-items: flex-start; }
.main-col { flex: 999 1 600px; min-width: 0; }
.sidebar { flex: 1 1 300px; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
.section-title { font-size: 26px; font-weight: 800; border-top: 3px solid var(--charcoal); padding-top: 12px; margin-bottom: 18px; }

/* Lead story */
.lead { display: flex; flex-wrap: wrap; gap: 28px; align-items: center; }
.lead-image { flex: 999 1 520px; min-width: 0; border-radius: var(--radius-lg); overflow: hidden; aspect-ratio: 16 / 10; background: var(--mist); }
.lead-image img { width: 100%; height: 100%; object-fit: cover; }
.lead-body { flex: 1 1 340px; min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.lead-title { font-size: 34px; font-weight: 800; letter-spacing: -0.5px; }
.lead-title a, .card-title a { color: var(--charcoal); text-decoration: none; }
.lead-title a:hover, .card-title a:hover { color: var(--teal-dark); text-decoration: underline; }
.lead-excerpt { margin: 0; color: var(--slate); font-size: 18px; }
.read-more { font-weight: 700; text-decoration: none; }

/* Topic chips */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.chip { display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; border-radius: 20px; border: 1px solid var(--line); font-size: 14px; font-weight: 600; color: var(--charcoal); text-decoration: none; }
.chip:hover { border-color: var(--teal); color: var(--teal-dark); }
.chip-on { background: var(--charcoal); border-color: var(--charcoal); color: #fff; }

/* Cards */
.post-list { display: flex; flex-direction: column; }
.card { display: flex; gap: 20px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.card-image { flex: 0 0 200px; aspect-ratio: 3 / 2; border-radius: var(--radius); overflow: hidden; background: var(--mist); }
.card-image img { width: 100%; height: 100%; object-fit: cover; }
.card-image-fallback { display: block; width: 100%; height: 100%; background: linear-gradient(135deg, #E8EEE4, #E4ECEE 55%, #E4E8F1); }
.card-body { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.card-meta-top { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.card-title { font-size: 20px; font-weight: 700; line-height: 1.25; }
.card-excerpt { margin: 0; font-size: 15px; color: var(--slate); }
.card-meta { margin: 0; font-size: 13px; color: var(--slate); }

/* Pagination */
.pagination { display: flex; justify-content: space-between; align-items: center; padding-top: 24px; font-weight: 600; }
.pagination a { text-decoration: none; }

/* Sidebar */
.promo { border-radius: var(--radius-lg); padding: 26px; background: linear-gradient(160deg, #EEF4DA, #E3F0EA 50%, #E3E9F4); display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.promo h3 { font-size: 24px; font-weight: 800; }
.promo p { margin: 0 0 6px; color: var(--slate); }
.ad { display: flex; flex-direction: column; gap: 4px; }
.ad-label { font-size: 11px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--slate); }
.ad img { border-radius: var(--radius); }
.ad-banner { margin: 0 auto; width: 100%; }
.ad-banner img { width: 100%; }

/* Subscribe */
.subscribe { border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 24px; display: flex; flex-direction: column; gap: 12px; }
.subscribe h2 { font-size: 20px; font-weight: 800; }
.subscribe p { margin: 4px 0 0; font-size: 15px; color: var(--slate); }
.subscribe-form { display: flex; flex-wrap: wrap; gap: 8px; }
.subscribe-form input { flex: 1 1 180px; min-height: 44px; padding: 0 14px; border: 1px solid #C5CCCF; border-radius: var(--radius); font: 400 16px var(--font); }
.form-msg { display: none; flex-basis: 100%; margin: 0; font-size: 14px; }
.subscribe-form.success .form-success, .subscribe-form.error .form-error { display: block; }
.subscribe-form.success input, .subscribe-form.success button { display: none; }
.subscribe-form.loading button { opacity: 0.6; }

/* Article */
.article-head { padding-top: 28px; display: flex; flex-direction: column; gap: 14px; max-width: 900px; margin-left: 0; }
.breadcrumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: 14px; color: var(--slate); }
.breadcrumbs a { color: var(--slate); }
.article-title { font-size: 44px; font-weight: 800; letter-spacing: -0.5px; }
.article-standfirst { margin: 0; font-size: 21px; color: var(--slate); }
.byline { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; font-size: 14px; color: var(--slate); }
.byline-author { display: inline-flex; align-items: center; gap: 10px; color: var(--charcoal); font-weight: 600; text-decoration: none; }
.byline-author img { border-radius: 50%; width: 44px; height: 44px; object-fit: cover; }
.article-image { margin-top: 26px; margin-bottom: 0; }
.article-image img { width: 100%; border-radius: var(--radius-lg); }
.article-image figcaption { font-size: 14px; color: var(--slate); padding-top: 8px; }
.article > .columns { padding-top: 32px; padding-bottom: 56px; }
.syndication { background: var(--mist); border-radius: var(--radius); padding: 12px 16px; font-size: 15px; }
.gh-content { font-size: 18px; line-height: 1.7; }
.gh-content > * + * { margin-top: 1.1em; }
.gh-content h2 { font-size: 28px; margin-top: 1.6em; }
.gh-content h3 { font-size: 22px; margin-top: 1.4em; }
.gh-content blockquote { margin-left: 0; padding-left: 20px; border-left: 4px solid var(--teal); font-size: 21px; color: var(--charcoal); }
.gh-content figure { margin: 1.6em 0; }
.gh-content figcaption { font-size: 14px; color: var(--slate); padding-top: 6px; }
.gh-content img { border-radius: var(--radius); }
.share { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; margin: 32px 0; padding: 14px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.share a { font-weight: 600; text-decoration: none; }
.author-box { display: flex; gap: 16px; align-items: flex-start; background: var(--mist); border-radius: var(--radius-lg); padding: 20px; margin: 28px 0; }
.author-box img { border-radius: 50%; width: 72px; height: 72px; object-fit: cover; }
.author-box h2 { font-size: 20px; }
.author-box h2 a { color: var(--charcoal); text-decoration: none; }
.author-box p { margin: 6px 0 0; font-size: 15px; color: var(--slate); }
.related { margin-top: 36px; }

/* Ghost card widths (required) */
.kg-width-wide { position: relative; width: min(85vw, 1040px); left: 50%; transform: translateX(-50%); }
.kg-width-full { position: relative; width: 100vw; left: 50%; transform: translateX(-50%); }
.kg-width-full img { border-radius: 0; }

/* Archive */
.archive-head { background: var(--mist); }
.archive-head .wrap { padding-top: 32px; padding-bottom: 32px; }
.archive-head h1 { font-size: 40px; font-weight: 800; margin-top: 6px; }
.archive-head p { margin: 8px 0 0; color: var(--slate); max-width: 760px; }
.author-head { display: flex; gap: 22px; align-items: center; }
.author-head img { border-radius: 50%; width: 96px; height: 96px; object-fit: cover; }

/* Footer */
.site-footer { background: var(--charcoal); color: #D9DEE0; font-size: 14px; }
.site-footer a { color: #fff; }
.footer-inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 32px; padding-top: 40px; padding-bottom: 28px; }
.footer-brand { flex: 1 1 320px; max-width: 460px; }
.footer-brand img { width: 240px; }
.footer-brand p { margin-top: 14px; }
.footer-nav ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(140px, auto)); gap: 8px 32px; }
.footer-nav a { text-decoration: none; }
.footer-base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; padding-top: 16px; padding-bottom: 24px; border-top: 1px solid #4A545A; color: #C9D2D5; }

/* Mobile */
@media (max-width: 760px) {
  .nav-toggle { display: inline-flex; align-items: center; }
  .header-search .search-btn span { display: none; }
  .site-nav { display: none; }
  .site-nav.is-open { display: block; }
  .site-nav ul { flex-direction: column; }
  .card { flex-direction: column; gap: 10px; }
  .card-image { flex-basis: auto; }
  .lead-title { font-size: 28px; }
  .article-title { font-size: 32px; }
  .welcome h1 { font-size: 28px; }
}
