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

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

:root {
  --green: #1F4B43;
  --green-light: #E8F4F0;
  --green-mid: #2D7A6B;
  --text: #111827;
  --text-mid: #374151;
  --text-muted: #6B7280;
  --border: #E5E7EB;
  --bg: #F9FAFB;
  --white: #ffffff;
}

body {
  font-family: 'Inter', sans-serif;
  color: var(--text);
  background: var(--white);
  line-height: 1.6;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; }

/* ── Nav ── */
.nav {
  background: var(--green);
  padding: 0 24px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: white;
  font-weight: 700;
  font-size: 17px;
  letter-spacing: -0.02em;
}

.nav-brand-icon {
  width: 30px; height: 30px;
  background: rgba(255,255,255,0.15);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav-links a {
  color: rgba(255,255,255,0.65);
  font-size: 13px;
  font-weight: 500;
  transition: color 0.15s;
}
.nav-links a:hover { color: white; }

.nav-cta {
  background: white;
  color: var(--green) !important;
  padding: 7px 18px;
  border-radius: 8px;
  font-weight: 700 !important;
  font-size: 13px !important;
}
.nav-cta:hover { opacity: 0.92; }

/* ── Hero (index) ── */
.hero {
  background: var(--green);
  padding: 64px 24px 56px;
  text-align: center;
}

.hero h1 {
  color: white;
  font-size: 42px;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 14px;
  max-width: 680px;
  margin-left: auto;
  margin-right: auto;
}

.hero p {
  color: rgba(255,255,255,0.65);
  font-size: 16px;
  max-width: 520px;
  margin: 0 auto;
}

/* ── Container ── */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ── Filters ── */
.filters {
  padding: 20px 0;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
  border-bottom: 1px solid var(--border);
  margin-bottom: 32px;
}

.filter-btn {
  padding: 6px 16px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  border: 1.5px solid var(--border);
  background: white;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.15s;
}
.filter-btn:hover, .filter-btn.active {
  background: var(--green);
  border-color: var(--green);
  color: white;
}

/* ── Post grid ── */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  padding-bottom: 64px;
}

@media (max-width: 900px) {
  .posts-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .posts-grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: 28px; }
}

/* ── Post card ── */
.post-card {
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  transition: box-shadow 0.2s, transform 0.15s;
  background: white;
  cursor: pointer;
  display: flex;
  flex-direction: column;
}
.post-card:hover {
  box-shadow: 0 8px 32px rgba(0,0,0,0.1);
  transform: translateY(-2px);
}

.post-card-img {
  width: 100%;
  height: 180px;
  overflow: hidden;
  background: var(--green-light);
}
.post-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s;
}
.post-card:hover .post-card-img img {
  transform: scale(1.03);
}

.post-card-title {
  padding: 14px 20px 8px;
}

.post-card-header {
  background: var(--green-light);
  padding: 20px 20px 14px;
}

.post-cat {
  display: inline-block;
  background: var(--green);
  color: white;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 10px;
}

.post-card h2 {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.35;
}

.post-card-body {
  padding: 16px 20px 20px;
}

.post-excerpt {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 14px;
}

.post-meta {
  font-size: 11px;
  color: #9CA3AF;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.read-more {
  font-size: 12px;
  font-weight: 600;
  color: var(--green);
}

/* ── Search bar ── */
.search-wrap {
  padding: 24px 0 0;
}

.search-input {
  width: 100%;
  max-width: 480px;
  padding: 10px 16px;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  transition: border-color 0.15s;
}
.search-input:focus { border-color: var(--green); }

/* ── Post page ── */
.post-page {
  max-width: 760px;
  margin: 0 auto;
  padding: 48px 24px 80px;
}

.post-page .post-cat {
  margin-bottom: 14px;
}

.post-page h1 {
  font-size: 34px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}

.post-date {
  font-size: 12px;
  color: #9CA3AF;
  margin-bottom: 32px;
  display: block;
}

.post-body {
  font-size: 16px;
  line-height: 1.75;
  color: var(--text-mid);
}

.post-body h2 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
  margin: 36px 0 12px;
  letter-spacing: -0.01em;
}

.post-body p { margin-bottom: 18px; }
.post-body ul, .post-body ol {
  margin: 0 0 18px 20px;
}
.post-body li { margin-bottom: 6px; }
.post-body strong { color: var(--text); font-weight: 600; }

/* ── Post hero image ── */
.post-hero-img {
  width: 100%;
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 32px;
  aspect-ratio: 16 / 7;
  background: var(--green-light);
}
.post-hero-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ── CTA box ── */
.cta-box {
  margin-top: 48px;
  background: var(--green);
  border-radius: 16px;
  padding: 32px;
  text-align: center;
}

.cta-box h3 {
  color: white;
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 8px;
}

.cta-box p {
  color: rgba(255,255,255,0.7);
  font-size: 14px;
  margin-bottom: 20px;
}

.cta-search-btn {
  display: inline-block;
  background: white;
  color: var(--green);
  font-weight: 700;
  font-size: 14px;
  padding: 12px 28px;
  border-radius: 10px;
  transition: opacity 0.15s;
}
.cta-search-btn:hover { opacity: 0.92; }

.cta-footnote {
  margin-top: 10px;
  font-size: 11px;
  color: rgba(255,255,255,0.45);
}

/* ── Back link ── */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 28px;
  transition: color 0.15s;
}
.back-link:hover { color: var(--green); }

/* ── Footer ── */
footer {
  background: var(--green);
  border-top: 1px solid rgba(255,255,255,0.08);
  padding: 36px 24px;
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  color: white;
  font-weight: 700;
  font-size: 15px;
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-links a {
  color: rgba(255,255,255,0.6);
  font-size: 13px;
  font-weight: 500;
  transition: color 0.15s;
}
.footer-links a:hover { color: white; }

.footer-copy {
  font-size: 11px;
  color: rgba(255,255,255,0.35);
  margin: 0;
}
