/*
 * Arborvine Blog Grid Widget – front-end styles
 * Matches the Project Resources page design language.
 */

/* ── Google Fonts ── */
@import url('https://fonts.googleapis.com/css2?family=Caveat:wght@500;600;700&family=Lato:wght@300;400;700&family=Playfair+Display:wght@400;500;600&display=swap');

/* ── Design tokens ── */
:root {
  --arb-green:       #2d4a35;
  --arb-gold:        #b89a4e;
  --arb-gold-hover:  #cdb06a;
  --arb-cream:       #f5f3ef;
  --arb-text:        #1c2b20;
  --arb-text-mid:    #4a5a50;
  --arb-text-light:  #7a8a80;
  --arb-border:      #e0dbd2;
}

/* ── Section label ── */
.arb-section-label {
  font-family: 'Lato', sans-serif;
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--arb-text-light);
  padding-bottom: 10px;
  border-bottom: 1px solid var(--arb-border);
  margin-bottom: 24px;
}

/* ── Grid layout ── */
.arb-blog-grid {
  display: grid;
  gap: 24px;
}

.arb-blog-grid--cols-1 { grid-template-columns: 1fr; }
.arb-blog-grid--cols-2 { grid-template-columns: repeat(2, 1fr); }
.arb-blog-grid--cols-3 { grid-template-columns: repeat(3, 1fr); }

/* ── Card ── */
.arb-blog-card {
  background: #fff;
  border: 1px solid var(--arb-border);
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 1px 4px rgba(0,0,0,.07);
  transition: box-shadow .2s ease, transform .2s ease;
  display: flex;
  flex-direction: column;
}

.arb-blog-card:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,.10);
  transform: translateY(-2px);
}

/* ── Thumbnail ── */
.arb-blog-thumb {
  position: relative;
  height: 200px;   /* overridden by Elementor slider control */
  overflow: hidden;
  display: block;
  text-decoration: none;
  flex-shrink: 0;
}

.arb-blog-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .4s ease;
}

.arb-blog-card:hover .arb-blog-thumb img {
  transform: scale(1.04);
}

.arb-blog-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10,25,15,.75) 0%, transparent 55%);
  display: flex;
  align-items: flex-end;
  padding: 20px;
}

.arb-blog-overlay-title {
  color: #fff;
  font-family: 'Playfair Display', serif;
  font-size: 1.15rem;
  font-weight: 500;
  line-height: 1.3;
  max-width: 88%;
}

.arb-blog-badge {
  position: absolute;
  top: 14px;
  left: 14px;
  font-family: 'Lato', sans-serif;
  font-size: .62rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(255,255,255,.9);
  background: rgba(0,0,0,.38);
  padding: 3px 8px;
  border-radius: 3px;
}

/* ── Body ── */
.arb-blog-body {
  padding: 22px 24px 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.arb-card-tag {
  display: inline-block;
  font-family: 'Lato', sans-serif;
  font-size: .62rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  border: 1px solid var(--arb-border);
  color: var(--arb-text-light);
  border-radius: 3px;
  padding: 2px 7px;
  margin-bottom: 10px;
}

.arb-blog-body h4 {
  font-family: 'Caveat', cursive;
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--arb-text);
  margin-bottom: 10px;
  line-height: 1.3;
}

.arb-blog-body h4 a {
  color: inherit;
  text-decoration: none;
  transition: color .2s;
}

.arb-blog-body h4 a:hover {
  color: var(--arb-green);
}

.arb-blog-body p {
  font-family: 'Lato', sans-serif;
  font-size: .875rem;
  color: var(--arb-text-mid);
  line-height: 1.65;
  margin-bottom: 18px;
  flex: 1;
}

/* ── Footer ── */
.arb-blog-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--arb-border);
  padding-top: 14px;
  margin-top: auto;
}

.arb-blog-date {
  font-family: 'Lato', sans-serif;
  font-size: .75rem;
  color: var(--arb-text-light);
}

.arb-cta-link {
  font-family: 'Lato', sans-serif;
  font-size: .8rem;
  font-weight: 700;
  color: var(--arb-text);
  text-decoration: none;
  letter-spacing: .04em;
  transition: color .2s;
  white-space: nowrap;
}

.arb-cta-link:hover {
  color: var(--arb-green);
}

/* ── No posts message ── */
.arb-no-posts {
  font-family: 'Lato', sans-serif;
  font-size: .875rem;
  color: var(--arb-text-light);
  padding: 24px 0;
}

/* ── Responsive ── */
@media (max-width: 768px) {
  .arb-blog-grid--cols-3 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 520px) {
  .arb-blog-grid--cols-2,
  .arb-blog-grid--cols-3 {
    grid-template-columns: 1fr;
  }
}
