/* Blog section inspired by Vincent's blog block */
.gallery-tablist-wrap {
  width: 100%;
  margin: 18px 0;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-behavior: smooth;
  scroll-padding: 0 4px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.gallery-tablist-wrap::-webkit-scrollbar {
  display: none;
}

.gallery-tablist {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-width: max-content;
  padding: 4px;
  border: 1px solid #d9e2ec;
  border-radius: 999px;
  background: #f7f9fb;
}

.gallery-tab-indicator {
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 0;
  border-radius: 999px;
  background: #1772d0;
  box-shadow: 0 8px 18px rgba(23, 114, 208, 0.14);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.26s ease, width 0.26s ease, height 0.26s ease, opacity 0.18s ease;
}

.gallery-tab-indicator.is-instant {
  transition: none;
}

.gallery-tab-button {
  position: relative;
  z-index: 1;
  flex: 0 0 auto;
  border: 0;
  background: transparent;
  color: #44576b;
  border-radius: 999px;
  padding: 8px 16px;
  font-family: 'Lato', 'Avenir Next', 'Helvetica Neue', Arial, sans-serif;
  font-size: 15px;
  line-height: 1.4;
  white-space: nowrap;
  cursor: pointer;
  transition: color 0.18s ease, transform 0.18s ease;
}

.gallery-tab-button:not(.is-active):hover {
  color: #1772d0;
}

.gallery-tab-button.is-active {
  color: #fff;
}

.gallery-tab-button:focus-visible {
  outline: 2px solid #1772d0;
  outline-offset: 2px;
}

.gallery-tab-panel {
  width: 100%;
  transform-origin: top center;
  will-change: transform, opacity;
}

.gallery-tab-panel[hidden] {
  display: none !important;
}

.gallery-tab-panels {
  position: relative;
  width: 100%;
  overflow: hidden;
  transition: height 0.38s cubic-bezier(0.22, 1, 0.36, 1);
}

.gallery-tab-panels.is-instant {
  transition: none;
}

.gallery-tab-panel.is-animating.is-from-right {
  animation: gallery-panel-slide-in-right 0.34s cubic-bezier(0.22, 1, 0.36, 1);
}

.gallery-tab-panel.is-animating.is-from-left {
  animation: gallery-panel-slide-in-left 0.34s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes gallery-panel-slide-in-right {
  from {
    opacity: 0.3;
    transform: translateX(72px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes gallery-panel-slide-in-left {
  from {
    opacity: 0.3;
    transform: translateX(-72px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@media (max-width: 768px) {
  .gallery-tablist-wrap {
    margin: 16px -4px 14px;
    padding: 0 4px 8px;
    scroll-snap-type: x proximity;
  }

  .gallery-tablist {
    gap: 3px;
  }

  .gallery-tab-button {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 8px 14px;
    font-size: 14px;
    scroll-snap-align: start;
  }

  .gallery-tab-panel {
    padding-top: 2px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .gallery-tablist-wrap {
    scroll-behavior: auto;
  }

  .gallery-tab-indicator,
  .gallery-tab-button,
  .gallery-tab-panel,
  .blog-carousel-track,
  .blog-card-link,
  .blog-carousel-button,
  .blog-carousel-dot {
    transition: none;
    animation: none;
  }
}

.blog-section-table {
  table-layout: fixed;
  max-width: 100%;
}

.blog-section-table .section-cell {
  box-sizing: border-box;
  min-width: 0;
}

.blog-panel {
  position: relative;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  margin-top: 6px;
  padding: 28px 30px 30px;
  border-radius: 28px;
  box-sizing: border-box;
  overflow: hidden;
}

.blog-panel {
  border: 1px solid #dbe3ec;
  background:
    radial-gradient(circle at top left, rgba(233, 241, 248, 0.38), transparent 34%),
    radial-gradient(circle at bottom right, rgba(250, 241, 231, 0.44), transparent 42%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.97) 0%, rgba(248, 250, 252, 0.99) 100%);
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.05);
}

.blog-panel > * {
  position: relative;
}

.blog-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 20px;
}

.blog-header-copy {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 680px;
}

.blog-header-copy heading {
  display: block;
  line-height: 1.08;
}

.blog-section-note {
  margin: 0;
  color: #607387;
  font-size: 15px;
  line-height: 1.75;
}

.blog-list {
  display: block;
  min-width: 0;
}

.blog-carousel {
  --blog-card-gap: 16px;
  --blog-cards-per-view: 2;
  min-width: 0;
  max-width: 100%;
}

.blog-carousel-viewport {
  position: relative;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  touch-action: pan-y pinch-zoom;
}

.blog-carousel-viewport:focus-visible {
  outline: 2px solid #1772d0;
  outline-offset: 5px;
  border-radius: 26px;
}

.blog-carousel-track {
  display: flex;
  align-items: stretch;
  gap: var(--blog-card-gap);
  min-width: 0;
  width: 100%;
  max-width: 100%;
  transition: transform 0.32s cubic-bezier(0.22, 0.61, 0.36, 1);
  will-change: transform;
}

.footer-table {
  width: 100%;
  border: 0;
  border-spacing: 0;
  border-collapse: separate;
}

.footer-top-cell {
  padding: 20px;
  width: 100%;
  vertical-align: top;
}

.blog-card {
  flex: 0 0 calc((100% - (var(--blog-card-gap) * (var(--blog-cards-per-view) - 1))) / var(--blog-cards-per-view));
  min-width: 0;
  max-width: 100%;
}

.blog-card-link {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 20px 22px 18px;
  border: 1px solid #dbe4ec;
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.99) 0%, rgba(244, 248, 251, 0.97) 100%);
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.05);
  text-decoration: none;
  color: inherit;
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.blog-card-link::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, rgba(23, 114, 208, 0.16), rgba(217, 130, 43, 0.24), rgba(23, 114, 208, 0.08));
}

.blog-card-link:hover {
  background: linear-gradient(180deg, rgba(255, 255, 255, 1) 0%, rgba(240, 246, 251, 0.98) 100%);
  border-color: #ccd9e6;
  box-shadow: 0 18px 34px rgba(47, 72, 95, 0.1);
  transform: translateY(-3px);
}

.blog-card-link:focus-visible {
  outline: 2px solid #1772d0;
  outline-offset: 3px;
}

.blog-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 18px;
}

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

.blog-card-date {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 30px;
  padding: 5px 12px;
  border: 1px solid #dbe3ea;
  border-radius: 999px;
  background: #eef2f6;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #4d6277;
  box-sizing: border-box;
}

.blog-card-reading {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 5px 12px;
  border: 1px solid #d8e3ee;
  border-radius: 999px;
  background: #edf4fb;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #436785;
  box-sizing: border-box;
}

.blog-card-title {
  display: block;
  margin: 0;
  font-size: 21px;
  font-weight: 600;
  line-height: 1.35;
  color: #2f3e4d;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.blog-card-desc {
  margin: 12px 0 0;
  font-size: 15px;
  line-height: 1.75;
  color: #5d7084;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
  overflow: hidden;
}

.blog-carousel-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 16px;
}

.blog-carousel.is-static .blog-carousel-controls {
  display: none;
}

.blog-carousel-button,
.blog-carousel-dot {
  border: 1px solid #d9e2ec;
  background: #f8fafc;
  color: #52677d;
  cursor: pointer;
  transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease, opacity 0.18s ease;
}

.blog-carousel-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  font-size: 15px;
  line-height: 1;
}

.blog-carousel-button:hover:not(:disabled),
.blog-carousel-dot:hover {
  background: #eef4fb;
  border-color: #c7d5e5;
  color: #1772d0;
  transform: translateY(-1px);
}

.blog-carousel-button:focus-visible,
.blog-carousel-dot:focus-visible {
  outline: 2px solid #1772d0;
  outline-offset: 3px;
}

.blog-carousel-button:disabled {
  cursor: default;
  opacity: 0.42;
  transform: none;
}

.blog-carousel-dots {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-width: 0;
}

.blog-carousel-dot {
  display: block;
  width: 8px;
  height: 8px;
  padding: 0;
  border-radius: 999px;
  background: #d7e1eb;
}

.blog-carousel-dot.is-active {
  width: 20px;
  background: #1772d0;
  border-color: #1772d0;
}

.blog-view-all {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border: 1px solid #d9e2ec;
  border-radius: 999px;
  background: #f8fafc;
  color: #2f3e4d;
  font-size: 14px;
  font-weight: 500;
  line-height: 1;
  white-space: nowrap;
  transition: background-color 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
}

.blog-view-all:hover {
  background: #eef4fb;
  border-color: #c7d5e5;
  color: #1772d0;
  transform: translateY(-1px);
}

.blog-loading,
.blog-error,
.blog-empty {
  grid-column: 1 / -1;
  padding: 20px 22px;
  border: 1px dashed #d7e2eb;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.72);
  color: #607387;
}
