/* ============================================================
   page-blogs.css  —  Blogs Archive Page
   Figma node  : 1961-4878
   Template    : page-blogs.php  (Template Name: Blogs Archive)
   Deps        : intone-design-system + intone-theme-tokens
   Version     : 1.0.0

   Sections
   ────────
   1.  Page wrapper
   2.  Breadcrumb
   3.  Hero (large "BLOGS" heading + gold accent)
   4.  Blog grid section
   5.  Blog card
   6.  Pagination
   7.  Empty state
   8.  Case Studies carousel (gold sidebar + cards)
   9.  Responsive
   10. Dark mode overrides
   ============================================================ */


/* ── 1. Page wrapper ─────────────────────────────────────── */
.intone-blogs-page {
  padding-top: clamp(80px, 12vw, 120px);
  background: #fff;
}


/* ── 2. Breadcrumb ──────────────────────────────────────── */
.blogs-breadcrumb {
  border-top: 1px solid #d3dae4;
  padding: 17px 44px 16px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0;
}

.blogs-breadcrumb__link {
  font-family: 'Public Sans', sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: #7b88a1;
  text-decoration: none;
  line-height: 24px;
  transition: color 0.2s;
}

.blogs-breadcrumb__link:hover { color: #233963; }

.blogs-breadcrumb__current {
  font-family: 'Public Sans', sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: #233963;
  line-height: 24px;
}


/* ── 3. Hero ─────────────────────────────────────────────── */
.blogs-hero {
  padding: 64px 44px 40px;
}

.blogs-hero__title {
  font-family: 'Public Sans', sans-serif;
  font-size: clamp(64px, 9.028vw, 130px);
  font-weight: 800;
  text-transform: uppercase;
  line-height: 1.15;
  color: #09101d;
  margin: 0;
}

.blogs-hero__accent {
  width: 192px;
  height: 6px;
  background: #f6b43f;
  margin-top: 8px;
}


/* ── 4. Blog grid section ────────────────────────────────── */
.blogs-grid-section {
  padding: 0 44px 96px;
}

.blogs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin-bottom: 64px;
}


/* ── 5. Blog card ────────────────────────────────────────── */
.blog-card {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.blog-card__image-link {
  display: block;
  text-decoration: none;
  flex-shrink: 0;
  border-radius: 12px;
  overflow: hidden;
}

.blog-card__image {
  height: 325px;
  border-radius: 12px;
  overflow: hidden;
  background: #f6f6f6;
}

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

.blog-card__image-link:hover .blog-card__image img {
  transform: scale(1.03);
}

.blog-card__image-placeholder {
  width: 100%;
  height: 100%;
  background: #ebeef2;
}

.blog-card__details {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.blog-card__meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.blog-card__author {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.blog-card__avatar {
  width: 32px;
  height: 32px;
  /* No circular clip — matches .post-header__avatar / .res-article-card__avatar
     so a brand favicon/squircle avatar shows fully here too instead of being
     cropped to a circle; object-fit:contain shows the whole image (square
     photos still fill the 1:1 box). */
  object-fit: contain;
  flex-shrink: 0;
  aspect-ratio: 1 / 1;
}

.blog-card__author-name {
  font-family: 'Public Sans', sans-serif;
  font-size: 14px;
  font-weight: 400;
  color: #1e2e4c;
  line-height: 20px;
  white-space: nowrap;
}

.blog-card__date {
  font-family: 'Public Sans', sans-serif;
  font-size: 14px;
  font-weight: 400;
  color: #9a9a9a;
  line-height: 16px;
  white-space: nowrap;
}

.blog-card__title {
  font-family: 'Public Sans', sans-serif;
  font-size: 24px;
  font-weight: 500;
  line-height: 32px;
  color: #1e2e4c;
  margin: 0;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.blog-card__title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s;
}

.blog-card__title a:hover { color: #233963; }

.blog-card__excerpt {
  font-family: 'Public Sans', sans-serif;
  font-size: 16px;
  font-weight: 400;
  line-height: 24px;
  color: #1e2e4c;
  margin: 0;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.blog-card__btn {
  display: inline-block;
  padding: 12px 16px;
  border: 2px solid #233963;
  color: #233963;
  font-family: 'Public Sans', sans-serif;
  font-size: 16px;
  font-weight: 500;
  text-transform: uppercase;
  text-decoration: none;
  width: 148px;
  text-align: center;
  line-height: 24px;
  flex-shrink: 0;
  align-self: flex-start;
  transition: background 0.2s ease, color 0.2s ease;
}

.blog-card__btn:hover {
  background: #233963;
  color: #fff;
}


/* ── 6. Pagination ───────────────────────────────────────── */
.blogs-pagination {
  display: flex;
  justify-content: center;
  padding: 32px 0 0;
}

.blogs-pagination__nav {
  display: flex;
  align-items: center;
  gap: 24px;
}

.blogs-pagination__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  color: #233963;
  text-decoration: none;
  border: none;
  background: none;
  cursor: pointer;
  transition: opacity 0.2s;
  line-height: 0;
}

.blogs-pagination__btn--disabled {
  opacity: 0.3;
  cursor: default;
  pointer-events: none;
}

.blogs-pagination__btn:hover:not(.blogs-pagination__btn--disabled) {
  opacity: 0.6;
}

.blogs-pagination__info {
  font-family: 'Public Sans', sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: #7b88a1;
}


/* ── 7. Empty state ──────────────────────────────────────── */
.blogs-empty {
  font-family: 'Public Sans', sans-serif;
  font-size: 16px;
  color: #666;
  padding: 24px 0;
}


/* ── 8. Case Studies carousel ────────────────────────────── */
.blogs-case-section {
  padding: 0 44px 96px;
}

.blogs-case-block {
  display: flex;
  align-items: stretch;
  gap: 24px;
}

/* Gold sidebar */
.blogs-case-sidebar {
  flex-shrink: 0;
  width: 360px;
  min-height: 616px;
  background: #f6b43f;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.blogs-case-sidebar__text {
  font-family: 'Public Sans', sans-serif;
  font-size: 68px;
  font-weight: 700;
  text-transform: uppercase;
  color: #09101d;
  writing-mode: vertical-rl;
  text-orientation: mixed;
  transform: rotate(180deg);
  white-space: nowrap;
  line-height: 1;
  letter-spacing: 0;
}

/* Carousel wrap */
.blogs-case-carousel-wrap {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.blogs-case-carousel {
  overflow: hidden;
}

.blogs-case-carousel__track {
  display: flex;
  gap: 24px;
  transition: transform 0.35s ease;
}

/* Individual case study card */
.blogs-case-card {
  flex-shrink: 0;
  /* ~3 cards visible at once; adjusted by JS */
  width: calc(33.333% - 16px);
  text-decoration: none;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.blogs-case-card__image {
  height: 440px;
  overflow: hidden;
  background: #ebeef2;
}

.blogs-case-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease;
}

.blogs-case-card:hover .blogs-case-card__image img {
  transform: scale(1.03);
}

.blogs-case-card__image-placeholder {
  width: 100%;
  height: 100%;
  background: #d9d9d9;
}

.blogs-case-card__category {
  display: inline-block;
  background: #f4f6f9;
  color: #1e2e4c;
  font-family: 'Public Sans', sans-serif;
  font-size: 14px;
  font-weight: 400;
  line-height: 20px;
  padding: 3px 12px;
}

.blogs-case-card__title {
  font-family: 'Public Sans', sans-serif;
  font-size: 24px;
  font-weight: 600;
  line-height: normal;
  color: #1e2e4c;
  margin: 0;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

/* Carousel nav buttons */
.blogs-case-carousel__nav {
  display: flex;
  gap: 16px;
}

.blogs-case-carousel__btn {
  width: 48px;
  height: 48px;
  border: 1.5px solid #233963;
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #233963;
  flex-shrink: 0;
  transition: background 0.2s ease, color 0.2s ease;
}

.blogs-case-carousel__btn:hover:not(:disabled) {
  background: #233963;
  color: #fff;
}

.blogs-case-carousel__btn:disabled {
  opacity: 0.3;
  cursor: default;
}


/* ── 9. Responsive ───────────────────────────────────────── */
@media (max-width: 1100px) {
  .blogs-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .blogs-case-sidebar {
    width: 240px;
    min-height: 480px;
  }
  .blogs-case-sidebar__text {
    font-size: 48px;
  }
  .blogs-case-card {
    width: calc(50% - 12px);
  }
}

@media (max-width: 768px) {
  .blogs-hero {
    padding: 40px 20px 28px;
  }
  .blogs-breadcrumb {
    padding: 12px 20px;
  }
  .blogs-grid-section {
    padding: 0 20px 64px;
  }
  .blogs-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .blogs-case-section {
    padding: 0 20px 64px;
  }
  .blogs-case-block {
    flex-direction: column;
  }
  .blogs-case-sidebar {
    width: 100%;
    min-height: 80px;
    padding: 20px;
  }
  .blogs-case-sidebar__text {
    writing-mode: horizontal-tb;
    transform: none;
    font-size: 36px;
  }
  .blogs-case-card {
    width: 80vw;
    min-width: 260px;
  }
}


/* ── 10. Dark mode overrides ─────────────────────────────── */
[data-theme="dark"] .intone-blogs-page {
  background: var(--t-bg);
}

[data-theme="dark"] .blogs-breadcrumb {
  border-top-color: var(--t-border);
}

[data-theme="dark"] .blogs-breadcrumb__link {
  color: var(--t-text-muted);
}

[data-theme="dark"] .blogs-breadcrumb__current {
  color: var(--t-text);
}

[data-theme="dark"] .blogs-hero__title {
  color: var(--t-text);
}

[data-theme="dark"] .blog-card__author-name,
[data-theme="dark"] .blog-card__excerpt {
  color: var(--t-text-muted);
}

[data-theme="dark"] .blog-card__title,
[data-theme="dark"] .blog-card__title a {
  color: var(--t-text);
}

[data-theme="dark"] .blog-card__title a:hover {
  color: var(--ds-gold, #f6b43f);
}

[data-theme="dark"] .blog-card__btn {
  border-color: var(--t-text);
  color: var(--t-text);
}

[data-theme="dark"] .blog-card__btn:hover {
  background: var(--t-text);
  color: var(--t-bg);
}

[data-theme="dark"] .blogs-pagination__btn {
  color: var(--t-text);
}

[data-theme="dark"] .blogs-pagination__info {
  color: var(--t-text-muted);
}

[data-theme="dark"] .blogs-case-card__title {
  color: var(--t-text);
}

[data-theme="dark"] .blogs-case-card__category {
  background: var(--t-surface);
  color: var(--t-text);
}

[data-theme="dark"] .blogs-case-carousel__btn {
  border-color: var(--t-border-strong);
  color: var(--t-text);
}

[data-theme="dark"] .blogs-case-carousel__btn:hover:not(:disabled) {
  background: var(--t-text);
  color: var(--t-bg);
}
