/* Blog main page (new design) - prefix bm- */
.bm-page { font-family: Aptos, "Segoe UI", Arial, sans-serif; color: #13232D; background: #fff; }
.bm-page *, .bm-page *::before, .bm-page *::after { box-sizing: border-box; }

/* Hero */
.bm-hero { padding: 48px 0 40px; }
.bm-hero__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
  gap: 56px;
  padding-left: max(24px, calc((100% - 1300px) / 2));
}
.bm-hero__title {
  margin: 0 0 16px;
  font-size: 80px; line-height: 88px; font-weight: 700; letter-spacing: -0.02em;
  color: #0252D7;
}
.bm-hero__desc {
  margin: 0 0 32px; max-width: 570px;
  font-size: 20px; line-height: 24px; font-weight: 400; color: #13232D;
}
.bm-hero__search { display: flex; align-items: center; gap: 24px; max-width: 570px; margin: 0; }
.bm-search { position: relative; flex: 1 1 auto; min-width: 0; }
.bm-search__input {
  width: 100%; height: 44px; padding: 0 48px 0 14px;
  border: 2px solid #3B4B57; border-radius: 8px; background: #fff;
  font: 400 18px/1 Aptos, "Segoe UI", Arial, sans-serif; color: #13232D;
}
.bm-search__input::placeholder { color: #4A5A66; opacity: 1; }
.bm-search__input:focus { outline: none; border-color: #0252D7; box-shadow: 0 0 0 3px rgba(2, 82, 215, 0.15); }
.bm-search__btn {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  width: 36px; height: 36px; padding: 0; border: 0; background: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.bm-hero__viewall {
  flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center;
  height: 44px; padding: 0 24px; border-radius: 8px;
  background: linear-gradient(135deg, #0252D7, #0044C2); color: #fff;
  font-size: 16px; font-weight: 600; text-decoration: none;
  box-shadow: 0 8px 24px rgba(2, 82, 215, 0.25);
}
.bm-hero__viewall:hover { filter: brightness(1.08); color: #fff; }
.bm-hero__media img {
  display: block; width: 100%; height: auto;
  aspect-ratio: 776 / 450; object-fit: cover; object-position: center 30%;
  border-radius: 28px 0 0 28px;
}

@media (max-width: 1100px) {
  .bm-hero__title { font-size: 56px; line-height: 62px; }
}
@media (max-width: 900px) {
  .bm-hero { padding: 40px 0 40px; }
  .bm-hero__inner { grid-template-columns: 1fr; gap: 32px; padding-right: 24px; padding-left: 24px; }
  .bm-hero__media img { border-radius: 20px; }
}
@media (max-width: 600px) {
  .bm-hero__title { font-size: 44px; line-height: 50px; }
  .bm-hero__desc { font-size: 18px; line-height: 26px; }
  .bm-hero__search { flex-wrap: wrap; }
  .bm-search { flex: 1 1 100%; }
}
/* Popular Topics */
.bm-topics { padding: 28px 0; background: linear-gradient(180deg, #fff 0%, #F5F7FB 100%); }
.bm-topics__inner {
  display: flex; align-items: center; justify-content: space-between; gap: 32px;
  padding: 0 max(24px, calc((100% - 1300px) / 2));
}
.bm-topics__label { margin: 0; flex: 0 0 auto; font-size: 20px; line-height: 28px; font-weight: 700; color: #0252D7; }
.bm-topics__pills { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 12px 16px; }
.bm-pill {
  height: 32px; padding: 0 14px; border: 1px solid #13232D; border-radius: 6px; background: #fff;
  font: 400 14px/1 Aptos, "Segoe UI", Arial, sans-serif; color: #13232D; cursor: pointer;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
.bm-pill:hover { border-color: #0252D7; color: #0252D7; }
.bm-pill[aria-pressed="true"] { background: #0252D7; border-color: #0252D7; color: #fff; }
.bm-pill:focus-visible { outline: 2px solid #0252D7; outline-offset: 2px; }

@media (max-width: 900px) {
  .bm-topics__inner { flex-direction: column; align-items: flex-start; gap: 16px; }
  .bm-topics__pills { justify-content: flex-start; }
}
/* Latest Blogs slider */
.bm-latest { padding: 72px 0 48px; overflow: hidden; }
.bm-latest__inner { padding: 0 max(24px, calc((100% - 1300px) / 2)); }
.bm-latest__title { margin: 0 0 8px; font-size: 40px; line-height: 48px; font-weight: 700; color: #13232D; }
.bm-slider__viewport { overflow: hidden; margin: 0 -48px; }
.bm-slider__track { display: flex; transition: transform .45s ease; }
.bm-slide { flex: 0 0 100%; min-width: 0; padding: 16px 48px 48px; }
.bm-slide__card {
  display: flex; align-items: center; gap: 56px; padding: 24px;
  background: #fff; border-radius: 40px; box-shadow: 0 12px 40px rgba(19, 35, 45, 0.12);
}
.bm-slide__img { flex: 0 0 300px; max-width: 35%; display: block; }
.bm-slide__img img { display: block; width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 20px; }
.bm-slide__body { flex: 1 1 auto; min-width: 0; }
.bm-slide__title { margin: 0 0 12px; font-size: 22px; line-height: 1.3; font-weight: 700; }
.bm-slide__title a { color: #13232D; text-decoration: none; }
.bm-slide__title a:hover { color: #0252D7; }
.bm-slide__excerpt { margin: 0 0 24px; font-size: 16px; line-height: 1.5; color: #4A5A66; }
.bm-btn {
  display: inline-flex; align-items: center; justify-content: center;
  height: 44px; padding: 0 28px; border-radius: 6px; background: #0252D7; color: #fff;
  font-size: 14px; font-weight: 600; text-decoration: none; transition: background-color .15s ease;
}
.bm-btn:hover { background: #0044C2; color: #fff; }
.bm-slider__controls { display: none; align-items: center; justify-content: center; gap: 16px; }
.bm-slider.is-ready .bm-slider__controls { display: flex; }
.bm-slider__arrow {
  width: 40px; height: 40px; padding: 0; border-radius: 50%; border: 2px solid #0252D7;
  background: #fff; color: #0252D7; cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: background-color .15s ease, color .15s ease;
}
.bm-slider__arrow:hover { background: #0252D7; color: #fff; }
.bm-slider__dots { display: flex; align-items: center; gap: 10px; }
.bm-slider__dot {
  width: 8px; height: 8px; padding: 0; border: 0; border-radius: 999px; background: #C8D4E8; cursor: pointer;
  transition: width .2s ease, background-color .2s ease;
}
.bm-slider__dot.is-active { width: 38px; background: #0252D7; }
@media (prefers-reduced-motion: reduce) { .bm-slider__track { transition: none; } }

@media (max-width: 900px) {
  .bm-latest { padding: 48px 0 32px; }
  .bm-latest__title { font-size: 32px; line-height: 40px; }
  .bm-slider__viewport { margin: 0 -16px; }
  .bm-slide { padding: 12px 16px 32px; }
  .bm-slide__card { flex-direction: column; align-items: stretch; gap: 20px; border-radius: 28px; }
  .bm-slide__img { flex: none; max-width: none; }
}
/* Trending Blogs */
.bm-trend {
  padding: 56px 0; color: #fff;
  background:
    radial-gradient(70% 120% at 0% 100%, rgba(2, 82, 215, 0.9) 0%, rgba(2, 82, 215, 0) 60%),
    radial-gradient(60% 100% at 100% 100%, rgba(0, 26, 114, 0.9) 0%, rgba(0, 26, 114, 0) 70%),
    linear-gradient(135deg, #001A72 0%, #0238B5 55%, #0252D7 100%);
}
.bm-trend__inner {
  display: grid; grid-template-columns: minmax(320px, 1.5fr) repeat(3, minmax(0, 1.1fr)); align-items: stretch;
  padding: 0 max(24px, calc((100% - 1300px) / 2));
}
.bm-trend__intro { align-self: center; padding-right: 40px; }
.bm-trend__title { margin: 0 0 20px; font-size: 48px; line-height: 56px; font-weight: 700; letter-spacing: 0; color: #fff; }
.bm-trend__text { margin: 0; font-size: 20px; line-height: 1.7; color: #fff; }
.bm-trend__card {
  display: flex; flex-direction: column; gap: 20px; padding: 8px 32px;
  border-left: 1px solid rgba(255, 255, 255, 0.55); color: #fff; text-decoration: none;
}
.bm-trend__intro + .bm-trend__card { border-left: 0; }
.bm-trend__media {
  position: relative; display: block; aspect-ratio: 43 / 30; border-radius: 24px; overflow: hidden; background: #001035;
}
.bm-trend__media img { display: block; width: 100%; height: 100%; object-fit: cover; }
.bm-trend__media::after { content: ""; position: absolute; inset: 0; background: #001035; opacity: 0; transition: opacity .2s ease; }
.bm-trend__more {
  position: absolute; inset: 0; margin: auto; z-index: 1; width: 58%; height: 52px;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid #fff; border-radius: 12px; color: #fff; font-size: 18px; font-weight: 600;
  opacity: 0; transition: opacity .2s ease;
}
@media (hover: hover) {
  .bm-trend__card:hover .bm-trend__media::after, .bm-trend__card:hover .bm-trend__more { opacity: 1; }
}
.bm-trend__card:focus-visible { outline: 2px solid #fff; outline-offset: 4px; }
.bm-trend__card:focus-visible .bm-trend__media::after, .bm-trend__card:focus-visible .bm-trend__more { opacity: 1; }
.bm-trend__name {
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
  text-align: center; font-size: 22px; line-height: 1.3; font-weight: 700; color: #fff;
}

@media (max-width: 1100px) {
  .bm-trend__inner { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .bm-trend__intro { grid-column: 1 / -1; padding: 0 0 32px; }
  .bm-trend__title { font-size: 44px; }
}
@media (max-width: 700px) {
  .bm-trend { padding: 40px 0; }
  .bm-trend__inner { grid-template-columns: 1fr; }
  .bm-trend__title { font-size: 36px; }
  .bm-trend__card { border-left: 0; border-top: 1px solid rgba(255, 255, 255, 0.4); padding: 24px 0; }
  .bm-trend__intro + .bm-trend__card { border-top: 0; }
}
/* Results: filter bar, grid, pagination */
.bm-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.bm-results { padding: 56px 0 96px; scroll-margin-top: 96px; }
.bm-results__inner { padding: 0 max(24px, calc((100% - 1300px) / 2)); }
.bm-filters {
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  margin: 0 0 48px; padding: 14px 20px; background: #fff; border-radius: 16px;
  box-shadow: 0 6px 28px rgba(19, 35, 45, 0.10);
}
.bm-filters .bm-search { flex: 0 1 440px; }
.bm-search--bar .bm-search__input { height: 40px; border-width: 1px; font-size: 15px; }
.bm-filters__selects { display: flex; align-items: center; gap: 32px; }
.bm-select select { width: 150px; text-overflow: ellipsis; }
.bm-select select {
  appearance: none; -webkit-appearance: none; border: 0; border-radius: 0; background-color: transparent;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'%3E%3Cpath d='M1 1.5l5 5 5-5' stroke='%2313232D' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 2px center; background-size: 12px 8px;
  padding: 6px 24px 6px 0; font: 400 15px/1.2 Aptos, "Segoe UI", Arial, sans-serif; color: #13232D; cursor: pointer;
}
.bm-select select:focus-visible { outline: 2px solid #0252D7; outline-offset: 4px; border-radius: 4px; }
.bm-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; }
.bm-card {
  display: flex; flex-direction: column; padding: 24px; background: #fff; border-radius: 28px;
  box-shadow: 0 10px 36px rgba(19, 35, 45, 0.10);
}
.bm-card__img { display: block; margin-bottom: 20px; }
.bm-card__img img { display: block; width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 18px; }
.bm-card__title {
  margin: 0 0 10px; font-size: 18px; line-height: 1.3; font-weight: 700;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.bm-card__title a { color: #13232D; text-decoration: none; }
.bm-card__title a:hover { color: #0252D7; }
.bm-card__excerpt {
  flex: 1 1 auto; margin: 0 0 20px; font-size: 14px; line-height: 1.55; color: #4A5A66;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.bm-card__btn { align-self: flex-start; height: 40px; padding: 0 22px; }
.bm-results__empty { grid-column: 1 / -1; margin: 0; padding: 48px 0; text-align: center; font-size: 18px; color: #4A5A66; }
.bm-pagination { display: flex; align-items: center; justify-content: center; gap: 10px; margin-top: 56px; }
.bm-pn {
  display: inline-flex; align-items: center; justify-content: center; min-width: 32px; height: 32px; padding: 0 8px;
  border: 1px solid #AEB8C4; border-radius: 4px; background: #fff; color: #13232D; font-size: 14px; text-decoration: none;
}
a.bm-pn:hover { border-color: #0252D7; color: #0252D7; }
.bm-pn.is-current { border-color: #0252D7; color: #0252D7; font-weight: 600; }
.bm-pn--gap { border: 0; min-width: auto; background: transparent; }

@media (max-width: 1000px) { .bm-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 900px) {
  .bm-results { padding: 40px 0 64px; }
  .bm-filters { flex-direction: column; align-items: stretch; gap: 16px; }
  .bm-filters .bm-search { flex: none; width: 100%; }
  .bm-filters__selects { flex-wrap: wrap; gap: 16px 24px; }
}
@media (max-width: 640px) { .bm-grid { grid-template-columns: 1fr; } }
/* Results: loading state and clear button */
.bm-results.is-loading .bm-grid { opacity: 0.45; pointer-events: none; transition: opacity 0.15s; }
.bm-clear { background: none; border: 0; padding: 6px 4px; font: 600 14px/1 Aptos, "Segoe UI", Arial, sans-serif; color: #0252D7; cursor: pointer; white-space: nowrap; }
.bm-clear:hover { text-decoration: underline; }
.bm-clear[hidden] { display: none; }
/* Results: custom dropdowns */
.bm-select.is-enhanced { display: none; }
.bm-dd { position: relative; }
.bm-dd__btn {
  appearance: none; -webkit-appearance: none; border: 0; border-radius: 0; background-color: transparent;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'%3E%3Cpath d='M1 1.5l5 5 5-5' stroke='%2313232D' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 2px center; background-size: 12px 8px;
  width: 150px; padding: 6px 24px 6px 0; text-align: left; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  font: 400 15px/1.2 Aptos, "Segoe UI", Arial, sans-serif; color: #13232D; cursor: pointer;
}
.bm-dd__btn[aria-expanded="true"] {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'%3E%3Cpath d='M1 6.5l5-5 5 5' stroke='%2313232D' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}
.bm-dd__btn.is-set { color: #0252D7; font-weight: 600; }
.bm-dd__btn:focus-visible { outline: 2px solid #0252D7; outline-offset: 4px; border-radius: 4px; }
.bm-dd__list {
  position: absolute; z-index: 30; top: calc(100% + 14px); left: -16px;
  min-width: 280px; max-width: calc(100vw - 32px); max-height: 320px; overflow-y: auto;
  margin: 0; padding: 8px 0; list-style: none; background: #fff;
  border: 1px solid #E1E6EB; border-radius: 12px; box-shadow: 0 12px 40px rgba(19, 35, 45, 0.16);
}
.bm-dd__list[hidden] { display: none; }
.bm-dd:last-child .bm-dd__list { left: auto; right: -16px; }
.bm-dd__opt { padding: 12px 24px 12px 32px; font: 400 16px/1.3 Aptos, "Segoe UI", Arial, sans-serif; color: #13232D; cursor: pointer; }
.bm-dd__opt:hover, .bm-dd__opt.is-active { background: #EEF4FF; }
.bm-dd__opt[aria-selected="true"] { color: #0252D7; font-weight: 600; }
/* Results: search-only filter bar (dropdowns hidden) */
@media (min-width: 901px) {
  .bm-filters--search-only { justify-content: flex-start; }
  .bm-filters--search-only .bm-search { flex: 0 1 560px; }
}