/* ============================================================
   RG Blog Posts Grid Widget — Styles
   ============================================================ */
:root {
  --rg-navy:        #0C1C2C;
  --rg-teal:        #447474;
  --rg-teal-bright: #5A9090;
  --rg-stone:       #A49C94;
  --rg-light:       #F4F4F4;
  --rg-charcoal:    #2B3640;
  --rg-white:       #FCFCFC;
  --rg-line-light:  rgba(12,28,44,.12);
  --rg-line:        rgba(164,156,148,.28);
}

/* ------------------------------------------------------------------
   Section header
   ------------------------------------------------------------------ */
.rg-blog-posts-widget .rg-posts-header {
  margin-bottom: 40px;
}

.rg-blog-posts-widget .rg-label {
  font-size: 11px;
  letter-spacing: .30em;
  text-transform: uppercase;
  color: var(--rg-teal);
  font-weight: 700;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.rg-blog-posts-widget .rg-label::before {
  content: "";
  width: 26px;
  height: 1px;
  background: var(--rg-teal);
  flex-shrink: 0;
}

.rg-blog-posts-widget .rg-posts-title {
  font-size: clamp(1.6rem, 2.6vw, 2.2rem);
  font-weight: 300;
  color: var(--rg-navy);
  letter-spacing: -.01em;
  line-height: 1.2;
}

/* ------------------------------------------------------------------
   Grid
   ------------------------------------------------------------------ */
.rg-posts-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}

/* ------------------------------------------------------------------
   Card
   ------------------------------------------------------------------ */
.rg-post-card {
  background: var(--rg-white);
  border: 1px solid var(--rg-line-light);
  border-radius: 4px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow .22s ease, transform .22s ease;
}
.rg-post-card:hover {
  box-shadow: 0 8px 32px rgba(12,28,44,.09);
  transform: translateY(-2px);
}

/* ------------------------------------------------------------------
   Thumbnail
   ------------------------------------------------------------------ */
.rg-card-thumb-link {
  display: block;
  overflow: hidden;
}
.rg-card-thumb {
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--rg-light);
}
.rg-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .38s ease;
}
.rg-post-card:hover .rg-card-thumb img {
  transform: scale(1.04);
}

/* Placeholder — editor preview (no real image available in JS template) */
.rg-card-thumb--placeholder {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--rg-light);
  border-bottom: 1px solid var(--rg-line);
}

/* Placeholder — post has no featured image set */
.rg-card-thumb--no-image {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--rg-light);
  border-bottom: 1px solid var(--rg-line);
  display: flex;
  align-items: center;
  justify-content: center;
}
.rg-card-thumb-icon {
  width: 48px;
  height: 48px;
  color: var(--rg-stone);
  opacity: .55;
}

/* ------------------------------------------------------------------
   Card body
   ------------------------------------------------------------------ */
.rg-card-body {
  padding: 28px 30px 30px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

/* Category label */
.rg-card-cat {
  display: block;
  font-size: 11px;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--rg-teal);
  font-weight: 700;
  margin-bottom: 14px;
}

/* Title */
.rg-card-title {
  font-size: clamp(1.05rem, 1.5vw, 1.32rem);
  font-weight: 400;
  color: var(--rg-navy);
  line-height: 1.26;
  letter-spacing: -.01em;
  margin-bottom: 12px;
}
.rg-card-title a {
  color: inherit;
  text-decoration: none;
  transition: color .2s;
}
.rg-card-title a:hover {
  color: var(--rg-teal);
}

/* Excerpt */
.rg-card-excerpt {
  font-size: .97rem;
  color: var(--rg-charcoal);
  line-height: 1.65;
  margin-bottom: 22px;
  flex: 1;
}

/* Read more */
.rg-card-read-more {
  display: inline-block;
  font-size: 11px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--rg-teal);
  font-weight: 700;
  text-decoration: none;
  padding-bottom: 2px;
  border-bottom: 1.5px solid transparent;
  transition: border-color .2s, color .2s;
  align-self: flex-start;
  margin-top: auto;
}
.rg-card-read-more:hover {
  color: var(--rg-navy);
  border-bottom-color: var(--rg-navy);
}

/* ------------------------------------------------------------------
   No posts message
   ------------------------------------------------------------------ */
.rg-no-posts {
  color: var(--rg-stone);
  font-size: .96rem;
  padding: 24px 0;
}

/* ------------------------------------------------------------------
   Responsive
   ------------------------------------------------------------------ */
@media (max-width: 768px) {
  .rg-posts-grid {
    grid-template-columns: 1fr !important;
  }
  .rg-card-body {
    padding: 22px 20px 24px;
  }
}
@media (min-width: 769px) and (max-width: 1024px) {
  .rg-card-title {
    font-size: 1.1rem;
  }
}
