@import url('https://fonts.googleapis.com/css2?family=Lora:ital,wght@0,400;0,500;1,400&family=Inter:wght@400;500&display=swap');

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

:root {
  --gh-font-heading: 'Lora', Georgia, serif;
  --gh-font-body: 'Inter', system-ui, sans-serif;
  --bg: #F7F5F2;
  --bg-alt: #F2EFEB;
  --surface: #FFFFFF;
  --border: #E8E4DF;
  --teal: #2BB5A0;
  --teal-light: #F0FAF8;
  --text: #1C1C1A;
  --text-muted: #7A766F;
  --text-faint: #B5B0A8;
  --font-serif: 'Lora', Georgia, serif;
  --font-sans: 'Inter', system-ui, sans-serif;
}

html { font-size: 16px; }

body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

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

/* ─── Layout ─── */
.container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* ─── Nav ─── */
.site-nav {
  border-bottom: 1px solid var(--border);
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 100;
}

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

.site-logo {
  font-family: var(--font-serif);
  font-size: 17px;
  font-weight: 500;
  color: var(--text);
  letter-spacing: -0.2px;
}

.site-logo span { color: var(--teal); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  list-style: none;
}

.nav-links a {
  font-size: 13px;
  color: var(--text-muted);
  transition: color 0.15s;
}

.nav-links a:hover { color: var(--text); }

.nav-cta {
  font-size: 12px !important;
  padding: 5px 13px;
  border: 1px solid var(--teal) !important;
  border-radius: 20px;
  color: var(--teal) !important;
}

/* ─── Hero ─── */
.site-hero {
  padding: 3rem 0 2rem;
  border-bottom: 1px solid var(--border);
}

.site-hero h1 {
  font-family: var(--font-serif);
  font-size: 28px;
  font-weight: 500;
  line-height: 1.35;
  letter-spacing: -0.3px;
  max-width: 560px;
  margin-bottom: 0.75rem;
}

.site-hero p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.75;
  max-width: 500px;
}

/* ─── Tag filter ─── */
.tag-filter {
  display: flex;
  gap: 0.5rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--border);
  overflow-x: auto;
  scrollbar-width: none;
}

.tag-filter::-webkit-scrollbar { display: none; }

.tag-pill {
  font-size: 12px;
  padding: 4px 12px;
  border-radius: 20px;
  border: 1px solid var(--border);
  color: var(--text-muted);
  white-space: nowrap;
  transition: all 0.15s;
}

.tag-pill:hover,
.tag-pill.active {
  border-color: var(--teal);
  color: var(--teal);
  background: var(--teal-light);
}

/* ─── Section label ─── */
.section-label {
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-bottom: 1.25rem;
}

/* ─── Featured post ─── */
.featured-section {
  padding: 2rem 0;
  border-bottom: 1px solid var(--border);
}

.featured-card {
  display: grid;
  grid-template-columns: 1fr 200px;
  gap: 2rem;
  align-items: start;
}

.featured-card .post-tag {
  display: inline-block;
  font-size: 11px;
  color: var(--teal);
  margin-bottom: 0.6rem;
}

.featured-card h2 {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 500;
  line-height: 1.35;
  letter-spacing: -0.3px;
  margin-bottom: 0.75rem;
  transition: color 0.15s;
}

.featured-card:hover h2 { color: var(--teal); }

.featured-card .excerpt {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 1.25rem;
}

.featured-thumb {
  background: var(--teal-light);
  border-radius: 10px;
  border: 1px solid var(--border);
  aspect-ratio: 3/2;
  overflow: hidden;
}

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

/* ─── Post meta ─── */
.post-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 12px;
  color: var(--text-faint);
}

.author-avatar {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #D4F0EB;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 9px;
  font-weight: 600;
  color: var(--teal);
  overflow: hidden;
  flex-shrink: 0;
}

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

/* ─── Post grid ─── */
.posts-section {
  padding: 2rem 0;
  border-bottom: 1px solid var(--border);
}

.posts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.post-card {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  padding-top: 1rem;
  border-top: 1.5px solid var(--border);
}

.post-card .post-tag {
  display: inline-block;
  font-size: 11px;
  color: var(--teal);
}

.post-card h3 {
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: -0.1px;
  transition: color 0.15s;
}

.post-card:hover h3 { color: var(--teal); }

.post-card .excerpt {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.6;
  flex: 1;
}

.post-card-meta {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: var(--text-faint);
  margin-top: 0.25rem;
}

/* ─── Pagination ─── */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  padding: 2rem 0;
  font-size: 13px;
  color: var(--text-muted);
}

.pagination a {
  padding: 6px 16px;
  border: 1px solid var(--border);
  border-radius: 20px;
  transition: all 0.15s;
}

.pagination a:hover {
  border-color: var(--teal);
  color: var(--teal);
}

/* ─── Single post ─── */
.post-header {
  padding: 3rem 0 2rem;
  border-bottom: 1px solid var(--border);
  max-width: 680px;
}

.post-header .post-tag {
  display: inline-block;
  font-size: 11px;
  color: var(--teal);
  margin-bottom: 0.75rem;
}

.post-header h1 {
  font-family: var(--font-serif);
  font-size: 32px;
  font-weight: 500;
  line-height: 1.25;
  letter-spacing: -0.5px;
  margin-bottom: 1rem;
}

.post-header .post-meta { margin-top: 1.5rem; }

.post-feature-image {
  margin: 2rem 0;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--border);
}

.post-content {
  max-width: 680px;
  padding: 2rem 0 3rem;
}

.post-content p {
  font-size: 16px;
  line-height: 1.8;
  color: var(--text);
  margin-bottom: 1.5rem;
}

.post-content h2 {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 500;
  margin: 2.5rem 0 1rem;
  letter-spacing: -0.3px;
}

.post-content h3 {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 500;
  margin: 2rem 0 0.75rem;
}

.post-content ul, .post-content ol {
  padding-left: 1.5rem;
  margin-bottom: 1.5rem;
}

.post-content li {
  font-size: 16px;
  line-height: 1.8;
  margin-bottom: 0.4rem;
}

.post-content blockquote {
  border-left: 2px solid var(--teal);
  padding-left: 1.25rem;
  margin: 2rem 0;
  font-family: var(--font-serif);
  font-style: italic;
  color: var(--text-muted);
  font-size: 17px;
  line-height: 1.7;
}

.post-content a { color: var(--teal); text-decoration: underline; }

.post-content code {
  font-family: 'Courier New', monospace;
  font-size: 13px;
  background: var(--bg-alt);
  padding: 2px 6px;
  border-radius: 4px;
  border: 1px solid var(--border);
}

.post-content pre {
  background: #1C1C1A;
  color: #F0F9F7;
  padding: 1.25rem;
  border-radius: 8px;
  overflow-x: auto;
  margin-bottom: 1.5rem;
  font-size: 13px;
  line-height: 1.6;
}

.post-content pre code {
  background: none;
  border: none;
  padding: 0;
  color: inherit;
  font-size: inherit;
}

/* ─── Footer ─── */
.site-footer {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  padding: 1.5rem 0;
}

.site-footer .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-logo {
  font-family: var(--font-serif);
  font-size: 14px;
  color: var(--text-muted);
}

.footer-logo span { color: var(--teal); }

.subscribe-form {
  display: flex;
  gap: 0.5rem;
}

.subscribe-form input {
  font-size: 12px;
  padding: 6px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  color: var(--text);
  width: 200px;
  outline: none;
  font-family: var(--font-sans);
  transition: border-color 0.15s;
}

.subscribe-form input:focus { border-color: var(--teal); }

.subscribe-form button {
  font-size: 12px;
  padding: 6px 16px;
  background: var(--teal);
  border: none;
  border-radius: 20px;
  color: #fff;
  font-weight: 500;
  cursor: pointer;
  font-family: var(--font-sans);
  transition: opacity 0.15s;
}

.subscribe-form button:hover { opacity: 0.85; }

/* ─── Responsive ─── */
@media (max-width: 768px) {
  .container { padding: 0 1.25rem; }
  .featured-card { grid-template-columns: 1fr; }
  .featured-thumb { display: none; }
  .posts-grid { grid-template-columns: 1fr; }
  .site-footer .container { flex-direction: column; gap: 1rem; }
  .nav-links { display: none; }
  .post-header h1 { font-size: 24px; }
}

/* ─── Koenig editor classes (required by Ghost) ─── */
.kg-width-wide {
  margin-left: calc(50% - 45vw);
  margin-right: calc(50% - 45vw);
  max-width: 90vw;
}

.kg-width-full {
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  max-width: 100vw;
}

.kg-image { max-width: 100%; height: auto; }

.kg-image-card { margin: 1.5rem 0; }

.kg-image-card img { border-radius: 8px; }

.kg-gallery-container { display: flex; flex-direction: column; gap: 0.5rem; margin: 1.5rem 0; }
.kg-gallery-row { display: flex; gap: 0.5rem; }
.kg-gallery-image { flex: 1; }
.kg-gallery-image img { width: 100%; height: 100%; object-fit: cover; border-radius: 6px; }

.kg-bookmark-card {
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  margin: 1.5rem 0;
}
.kg-bookmark-container { display: flex; text-decoration: none; color: inherit; }
.kg-bookmark-content { padding: 1rem; flex: 1; }
.kg-bookmark-title { font-weight: 500; font-size: 14px; margin-bottom: 0.25rem; }
.kg-bookmark-description { font-size: 12px; color: var(--text-muted); }
.kg-bookmark-thumbnail img { width: 120px; height: 100%; object-fit: cover; }

.kg-callout-card {
  display: flex;
  gap: 1rem;
  padding: 1rem 1.25rem;
  border-radius: 8px;
  background: var(--teal-light);
  border: 1px solid var(--border);
  margin: 1.5rem 0;
  font-size: 15px;
  line-height: 1.6;
}

.kg-toggle-card { border: 1px solid var(--border); border-radius: 8px; margin: 1.5rem 0; }
.kg-toggle-heading { padding: 0.75rem 1rem; font-weight: 500; cursor: pointer; }
.kg-toggle-content { padding: 0 1rem 0.75rem; font-size: 14px; color: var(--text-muted); }

.kg-video-card { margin: 1.5rem 0; }
.kg-video-card video { width: 100%; border-radius: 8px; }

.kg-divider { border: none; border-top: 1px solid var(--border); margin: 2rem 0; }

.kg-audio-card { margin: 1.5rem 0; }

.kg-button-card { margin: 1.5rem 0; text-align: center; }
.kg-btn {
  display: inline-block;
  padding: 10px 24px;
  background: var(--teal);
  color: #fff;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
}
