/* Pezo blog — editorial layout (reference-inspired) */

@keyframes pezoBlogShimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

.pezo-blog-page {
  background: #fff;
  min-height: 60vh;
  /* Clear fixed header (desktop: 100px, mobile nav ~80px) */
  padding-top: 120px;
  padding-bottom: 4rem;
}

.pezo-blog-page > .container {
  max-width: 1140px;
}

/* ---- List page ---- */

.pezo-blog-page-header {
  text-align: center;
  margin-bottom: 2.5rem;
  padding-top: 0.25rem;
}

.pezo-blog-page-header h1 {
  font-family: "Quicksand", sans-serif;
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  color: #231f20;
  margin: 0 0 0.65rem;
  line-height: 1.2;
}

.pezo-blog-page-header p {
  font-size: 1.05rem;
  color: #666;
  margin: 0 auto;
  line-height: 1.6;
  max-width: 42rem;
}

/* ---- Search toolbar ---- */

.pezo-blog-toolbar {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 1.25rem;
}

.pezo-blog-page input.pezo-blog-search-input[type="search"] {
  width: 240px;
  max-width: 100%;
  box-sizing: border-box;
  margin: 0;
  padding: 0.5rem 0.75rem;
  border: 1px solid #ddd;
  border-radius: 4px;
  background: #fff;
  color: #231f20;
  font-size: 0.9375rem;
  line-height: 1.4;
  outline: none;
}

.pezo-blog-page input.pezo-blog-search-input[type="search"]:focus {
  border-color: #bbb;
  background: #fff;
  color: #231f20;
}

.pezo-blog-page input.pezo-blog-search-input[type="search"]::placeholder {
  color: #aaa;
}

.pezo-blog-page input.pezo-blog-search-input[type="search"]::-webkit-search-cancel-button {
  cursor: pointer;
}

@media (max-width: 575.98px) {
  .pezo-blog-toolbar {
    justify-content: stretch;
  }

  .pezo-blog-page input.pezo-blog-search-input[type="search"] {
    width: 100%;
  }
}

.pezo-blog-load-sentinel {
  height: 1px;
  width: 100%;
}

.pezo-blog-load-status {
  text-align: center;
  font-size: 0.875rem;
  color: #888;
  margin: 1.5rem 0 0;
}

.pezo-blog-grid--loading {
  margin-top: 2rem;
}

/* ---- List grid (3 columns on desktop) ---- */

.pezo-blog-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem 1.5rem;
}

.pezo-blog-card {
  height: 100%;
}

.pezo-blog-card-link {
  display: flex;
  flex-direction: column;
  height: 100%;
  text-decoration: none;
  color: inherit;
}

.pezo-blog-card-link:hover {
  text-decoration: none;
  color: inherit;
}

.pezo-blog-card-media {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 8px;
  background: #eee;
  margin-bottom: 1rem;
}

.pezo-blog-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease;
}

.pezo-blog-card-link:hover .pezo-blog-card-media img {
  transform: scale(1.04);
}

.pezo-blog-card-body {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.pezo-blog-card-title {
  font-family: "Quicksand", sans-serif;
  font-size: 1.125rem;
  font-weight: 700;
  color: #231f20;
  line-height: 1.35;
  margin: 0 0 0.65rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color 0.2s ease;
}

.pezo-blog-card-link:hover .pezo-blog-card-title {
  color: #e63946;
}

.pezo-blog-card-excerpt {
  font-size: 0.9375rem;
  line-height: 1.6;
  color: #555;
  margin: 0 0 0.65rem;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.pezo-blog-card-meta {
  font-size: 0.8125rem;
  color: #999;
  margin: 0 0 0.75rem;
}

.pezo-blog-card-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.9375rem;
  font-weight: 600;
  color: #e63946;
  margin-top: auto;
}

.pezo-blog-card-cta i {
  font-size: 0.75rem;
  transition: transform 0.2s ease;
}

.pezo-blog-card-link:hover .pezo-blog-card-cta i {
  transform: translateX(4px);
}

.pezo-blog-card--skel .pezo-blog-skel-card-img {
  aspect-ratio: 16 / 9;
  margin-bottom: 1rem;
  border-radius: 8px;
}

@media (min-width: 576px) {
  .pezo-blog-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 992px) {
  .pezo-blog-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 2.25rem 1.75rem;
  }

  .pezo-blog-card-title {
    font-size: 1.2rem;
  }
}

/* ---- Detail page ---- */

.pezo-blog-detail-page {
  padding-bottom: 4rem;
}

.pezo-blog-back {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: #555;
  text-decoration: none;
  margin-bottom: 2rem;
  transition: color 0.2s ease;
}

.pezo-blog-back:hover {
  color: #e63946;
}

.pezo-blog-detail-title {
  font-family: "Quicksand", sans-serif;
  font-size: clamp(1.4rem, 3.5vw, 2rem);
  font-weight: 700;
  color: #e63946;
  text-align: center;
  line-height: 1.25;
  margin: 0 0 1.5rem;
}

.pezo-blog-detail-hero {
  width: 100%;
  margin-bottom: 0;
  overflow: hidden;
  background: #f0f0f0;
}

.pezo-blog-detail-hero img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  max-height: 480px;
}

@media (min-width: 992px) {
  .pezo-blog-detail-hero img {
    max-height: 560px;
  }

  .pezo-blog-detail-title {
    font-size: clamp(1.65rem, 2.5vw, 2.35rem);
  }
}

.pezo-blog-detail-meta {
  font-size: 0.875rem;
  color: #888;
  margin: 1.25rem 0 0.75rem;
  text-align: left;
}

.pezo-blog-detail-excerpt {
  font-size: 1.05rem;
  line-height: 1.65;
  color: #444;
  margin: 0 0 1.25rem;
}

/* Rich text prose + Quill alignment */

.pezo-blog-prose {
  font-size: 1rem;
  line-height: 1.75;
  color: #231f20;
  padding: 1.5rem 0 2rem;
}

.pezo-blog-prose p {
  margin: 0 0 1.15rem;
  color: #231f20;
}

.pezo-blog-prose h2 {
  font-family: "Quicksand", sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  color: #231f20;
  margin: 2rem 0 0.75rem;
  line-height: 1.35;
}

.pezo-blog-prose h3 {
  font-family: "Quicksand", sans-serif;
  font-size: 1.05rem;
  font-weight: 700;
  color: #231f20;
  margin: 1.5rem 0 0.6rem;
}

.pezo-blog-prose ul,
.pezo-blog-prose ol {
  margin: 0 0 1.15rem 1.25rem;
  padding: 0;
}

.pezo-blog-prose li {
  margin-bottom: 0.4rem;
}

.pezo-blog-prose a {
  color: #e63946;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.pezo-blog-prose a:hover {
  color: #c1121f;
}

.pezo-blog-prose blockquote {
  margin: 1.5rem 0;
  padding: 0 0 0 1rem;
  border-left: 3px solid #e63946;
}

.pezo-blog-prose blockquote p {
  margin: 0;
  font-style: italic;
  color: #444;
}

.pezo-blog-prose figure {
  margin: 1.75rem 0;
}

.pezo-blog-prose img,
.blog-content img {
  max-width: 100%;
  height: auto;
  display: block;
}

.blog-content .ql-align-center,
.pezo-blog-prose .ql-align-center {
  text-align: center;
}

.blog-content .ql-align-right,
.pezo-blog-prose .ql-align-right {
  text-align: right;
}

.blog-content .ql-align-justify,
.pezo-blog-prose .ql-align-justify {
  text-align: justify;
}

.blog-content .ql-align-center img,
.pezo-blog-prose .ql-align-center img {
  margin-left: auto;
  margin-right: auto;
}

/* Related */

.pezo-blog-related {
  border-top: 1px solid #ececec;
  padding-top: 2rem;
  margin-top: 0.5rem;
}

.pezo-blog-related-title {
  font-family: "Quicksand", sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: #231f20;
  margin: 0 0 1.25rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.pezo-blog-related-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.pezo-blog-related-list li {
  margin-bottom: 1.25rem;
}

.pezo-blog-related-list li:last-child {
  margin-bottom: 0;
}

.pezo-blog-related-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.pezo-blog-related-link:hover {
  text-decoration: none;
  color: inherit;
}

.pezo-blog-related-link:hover .pezo-blog-related-item-title {
  color: #e63946;
}

.pezo-blog-related-item-title {
  font-family: "Quicksand", sans-serif;
  font-size: 1.05rem;
  font-weight: 700;
  color: #231f20;
  margin: 0 0 0.25rem;
  line-height: 1.35;
  transition: color 0.2s ease;
}

.pezo-blog-related-item-meta {
  font-size: 0.8125rem;
  color: #888;
  margin: 0;
}

/* CTA */

.pezo-blog-cta {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid #ececec;
  text-align: center;
}

.pezo-blog-cta-text {
  font-size: 1rem;
  color: #444;
  margin: 0 0 1.25rem;
  line-height: 1.55;
}

.pezo-blog-cta-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
}

/* Empty + error */

.pezo-blog-empty,
.pezo-blog-detail-error {
  text-align: center;
  padding: 3rem 0;
  color: #666;
}

.pezo-blog-detail-error-msg {
  color: #555;
  margin-bottom: 1.5rem;
  font-size: 1.05rem;
}

/* Skeleton */

.pezo-blog-skel {
  border-radius: 4px;
  background: linear-gradient(90deg, #ececec 0%, #f5f5f5 45%, #ececec 90%);
  background-size: 200% 100%;
  animation: pezoBlogShimmer 1.15s ease-in-out infinite;
}

.pezo-blog-skel-title {
  height: 28px;
  max-width: 85%;
  margin: 0 auto 1.25rem;
}

.pezo-blog-skel-img {
  height: 220px;
  margin-bottom: 1rem;
}

.pezo-blog-skel-line {
  height: 14px;
  margin-bottom: 0.6rem;
}

.pezo-blog-skel-line--short {
  width: 35%;
}

.pezo-blog-skel-block {
  height: 100px;
  margin-top: 1.5rem;
}

@media (max-width: 991.98px) {
  .pezo-blog-page {
    padding-top: 100px;
  }
}

@media (min-width: 1200px) {
  .pezo-blog-page > .container {
    max-width: 1140px;
  }
}

@media (min-width: 1400px) {
  .pezo-blog-page > .container {
    max-width: 1320px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .pezo-blog-skel {
    animation: none;
  }
}
