/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

:root {
  --page-bg: #fbfaf7;
  --ink: #1f2933;
  --muted: #5f6f7b;
  --line: #d7dde1;
  --surface: #ffffff;
  --accent: #1c6b6f;
  --accent-dark: #114b50;
  --warm: #b45f38;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--page-bg);
  color: var(--ink);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

a {
  color: var(--accent-dark);
  text-underline-offset: 0.18em;
}

img {
  max-width: 100%;
  height: auto;
}

.blog-shell {
  width: min(1080px, calc(100% - 32px));
  margin: 0 auto;
  padding: 56px 0 72px;
}

.blog-header,
.post-header {
  max-width: 760px;
  margin-bottom: 32px;
}

.blog-kicker,
.post-card-meta,
.post-date,
.post-card-date {
  color: var(--muted);
  font-size: 0.92rem;
}

.blog-kicker,
.post-card-meta {
  margin: 0 0 8px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

.blog-header h1,
.post-header h1 {
  margin: 0;
  font-family: ui-serif, Georgia, Cambria, "Times New Roman", serif;
  font-size: clamp(2.25rem, 6vw, 4.5rem);
  line-height: 1;
}

.blog-header p:not(.blog-kicker),
.post-header p:not(.blog-kicker) {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 1.08rem;
}

.post-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  gap: 24px;
}

.post-card {
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.post-card-image-link {
  display: block;
}

.post-card-image {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

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

.post-card h2 {
  margin: 0;
  font-family: ui-serif, Georgia, Cambria, "Times New Roman", serif;
  font-size: 1.45rem;
  line-height: 1.15;
}

.post-card h2 a {
  color: var(--ink);
  text-decoration: none;
}

.post-card h2 a:hover {
  color: var(--accent-dark);
  text-decoration: underline;
}

.post-card-date {
  margin: 10px 0;
}

.post-card p:last-child {
  margin-bottom: 0;
}

.empty-state {
  max-width: 640px;
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.empty-state h2 {
  margin-top: 0;
}

.post-article {
  max-width: 860px;
}

.post-hero-image {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--line);
}

.post-body {
  max-width: 720px;
  margin-top: 36px;
  font-family: ui-serif, Georgia, Cambria, "Times New Roman", serif;
  font-size: 1.18rem;
}

.post-body p {
  margin: 0 0 1.2em;
}

@media (max-width: 640px) {
  .blog-shell {
    width: min(100% - 24px, 1080px);
    padding-top: 36px;
  }

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