/* Articles pages – consistent with Metashift design (index.css variables) */

.articles-page{
  padding: 8rem 2rem 5rem; /* accounts for fixed navbar */
  background: var(--light-bg);
}

.articles-container{
  max-width: 1300px;
  margin: 0 auto;
}

.articles-search{
  display:flex;
  gap: 1rem;
  margin: 1.5rem 0 2.5rem;
  flex-wrap: wrap;
}

.articles-search input{
  flex: 1;
  min-width: 260px;
  padding: 1rem;
  border: 1px solid var(--silver);
  border-radius: 4px;
  font-size: 1rem;
  font-family: inherit;
  background: var(--white);
  color: var(--charcoal);
}

.articles-search input:focus{
  outline: none;
  border-color: var(--accent-teal);
}

.articles-grid{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
}

.article-card{
  background: var(--white);
  padding: 2rem;
  border: 1px solid var(--silver);
  text-decoration: none;
  transition: all 0.3s;
  display: block;
}

.article-card:hover{
  transform: translateY(-5px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.08);
  border-color: var(--accent-teal);
}

.article-card-top{
  display:flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.article-card h3{
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--charcoal);
  line-height: 1.25;

  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.article-date{
  color: var(--slate);
  font-size: 0.9rem;
  white-space: nowrap;
  margin-top: 0.2rem;
}

.article-excerpt{
  color: var(--slate);
  line-height: 1.7;
  font-size: 0.98rem;

  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.article-cta{
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--silver);
  display:flex;
  align-items:center;
  justify-content: space-between;
  color: var(--accent-teal);
  font-weight: 700;
}

.article-cta .arrow{
  transition: transform 0.3s;
}
.article-card:hover .article-cta .arrow{
  transform: translateX(6px);
}

/* Detail page */
.article-back{
  display:inline-block;
  margin-bottom: 1.5rem;
  text-decoration: none;
  color: var(--accent-teal);
  font-weight: 700;
}

.article-header{
  margin-bottom: 2rem;
}

.article-title{
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800;
  color: var(--charcoal);
  margin: 1rem 0 0.5rem;
  letter-spacing: -1.5px;
}

.article-body{
  background: var(--white);
  border: 1px solid var(--silver);
  padding: 2rem;
  line-height: 1.85;
  color: var(--charcoal);
  font-size: 1.02rem;
}

/* Responsive */
@media (max-width: 768px){
  .articles-page{ padding: 6rem 1.5rem 3rem; }
  .article-body{ padding: 1.5rem; }
}


.article-body h2{
  margin-top: 2.2rem;
  margin-bottom: 0.9rem;
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--charcoal);
  letter-spacing: -0.5px;
}

.article-body p{
  margin: 0 0 1.1rem;
  color: var(--slate);
  font-size: 1.02rem;
  line-height: 1.85;
}

/* Make the first paragraph look like an intro */
.article-body p:first-of-type{
  color: var(--charcoal);
  font-size: 1.08rem;
}
