.b2biz-directory-wrap {
  padding: 18px 0 38px;
  color: #1f2937;
  font-size: 14px;
  line-height: 1.55;
}

.b2biz-directory-wrap,
.b2biz-directory-wrap * {
  box-sizing: border-box;
}

.b2biz-directory-layout {
  display: grid;
  grid-template-columns: 324px minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}

.b2biz-directory-side {
  display: grid;
  gap: 16px;
}

.b2biz-directory-rank,
.b2biz-directory-featured,
.b2biz-directory-toolbar,
.b2biz-directory-join {
  border: 1px solid #edf0f4;
  background: #fff;
}

.b2biz-directory-rank {
  min-height: 630px;
  padding: 0 22px 18px;
}

.b2biz-directory-rank h2,
.b2biz-directory-title-row h1 {
  margin: 0;
  color: #111827;
  font-size: 20px;
  font-weight: 500;
  line-height: 52px;
}

.b2biz-directory-rank ol {
  display: grid;
  gap: 13px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.b2biz-directory-rank li {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  min-height: 48px;
}

.b2biz-directory-rank em {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 5px;
  background: #eef2f7;
  color: #8b95a1;
  font-style: normal;
  font-weight: 600;
}

.b2biz-directory-rank li:nth-child(-n+3) em {
  background: #e93232;
  color: #fff;
}

.b2biz-directory-rank a {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  color: #111827;
  font-size: 15px;
  text-decoration: none;
}

.b2biz-directory-rank img {
  width: 42px;
  height: 42px;
  border: 1px solid #edf0f4;
  border-radius: 50%;
  object-fit: cover;
}

.b2biz-directory-rank span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.b2biz-directory-join {
  position: relative;
  display: grid;
  gap: 8px;
  min-height: 124px;
  padding: 28px 122px 24px 28px;
  color: #4b5563;
  text-decoration: none;
  overflow: hidden;
}

.b2biz-directory-join strong {
  color: #374151;
  font-size: 20px;
  line-height: 1.35;
}

.b2biz-directory-join span {
  color: #8b95a1;
  font-size: 15px;
}

.b2biz-directory-join i {
  position: absolute;
  right: 26px;
  top: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 66px;
  height: 66px;
  border: 1px solid #ffb4b4;
  border-radius: 50%;
  background: #fff5f5;
  color: #f46f73;
  font-size: 32px;
  font-style: normal;
}

.b2biz-directory-join svg {
  width: 34px;
  height: 34px;
}

.b2biz-directory-main {
  display: grid;
  gap: 18px;
  min-width: 0;
}

.b2biz-directory-list {
  margin-top: 32px;
}

.b2biz-directory-featured {
  padding: 0 18px 20px;
}

.b2biz-directory-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.b2biz-directory-title-row a {
  color: #9aa3ad;
  font-size: 14px;
  text-decoration: none;
}

.b2biz-directory-featured-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

.b2biz-directory-card {
  min-width: 0;
  background: #fff;
}

.b2biz-directory-card-featured {
  padding: 16px 16px 18px;
}

.b2biz-directory-card-compact {
  min-height: 230px;
  padding: 22px;
}

.b2biz-directory-card-head {
  display: grid;
  grid-template-columns: 82px minmax(0, 1fr) 68px;
  gap: 14px;
  align-items: center;
  padding: 16px 18px;
  background: #fbfbfc;
}

.b2biz-directory-card-compact .b2biz-directory-card-head {
  grid-template-columns: 80px minmax(0, 1fr);
  gap: 16px;
  padding: 0 0 18px;
  background: #fff;
}

.b2biz-directory-card-logo {
  display: block;
  width: 82px;
  height: 82px;
  padding: 4px;
  border: 4px solid #80bfff;
  border-radius: 50%;
  background: #fff;
  overflow: hidden;
}

.b2biz-directory-card-compact .b2biz-directory-card-logo {
  width: 78px;
  height: 78px;
  padding: 2px;
  border-width: 1px;
  border-color: #e4e7ec;
  border-radius: 4px;
}

.b2biz-directory-card-logo img {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}

.b2biz-directory-card-compact .b2biz-directory-card-logo img {
  border-radius: 3px;
}

.b2biz-directory-card-main {
  min-width: 0;
}

.b2biz-directory-card-main h3 {
  margin: 0 0 8px;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.35;
}

.b2biz-directory-card-main h3 a {
  display: block;
  overflow: hidden;
  color: #111827;
  text-decoration: none;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.b2biz-directory-card-main p {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin: 0;
  color: #7b8794;
  font-size: 14px;
  line-height: 1.45;
}

.b2biz-directory-stars {
  color: #2f9bea;
  font-size: 20px;
  line-height: 1;
}

.b2biz-directory-card-main em {
  font-style: normal;
}

.b2biz-directory-score {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 6px;
  color: #7b8794;
  font-size: 14px;
}

.b2biz-directory-score b {
  margin-left: 2px;
  color: #ff2f2f;
  font-weight: 400;
}

.b2biz-directory-card-actions {
  display: grid;
  gap: 8px;
}

.b2biz-directory-card-compact .b2biz-directory-card-actions {
  grid-column: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: -4px;
}

.b2biz-directory-card-compact .b2biz-directory-card-actions a,
.b2biz-directory-card-compact .b2biz-directory-card-actions button {
  min-width: 66px;
  padding: 0 8px;
}

.b2biz-directory-card-actions a,
.b2biz-directory-card-actions button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-width: 74px;
  min-height: 36px;
  padding: 0 10px;
  border: 1px solid #dfe3e8;
  border-radius: 3px;
  background: #fff;
  color: #374151;
  font-size: 14px;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
}

.b2biz-directory-card-actions a:hover,
.b2biz-directory-card-actions button:hover,
.b2biz-directory-card-actions button.active {
  border-color: #88bfff;
  color: #2f80ed;
}

.b2biz-directory-card-actions svg {
  width: 16px;
  height: 16px;
}

.b2biz-directory-products {
  margin-top: 10px;
}

.b2biz-directory-card-compact .b2biz-directory-products {
  margin-top: 2px;
}

.b2biz-directory-products h4 {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  margin: 0 0 10px;
  color: #111827;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.4;
}

.b2biz-directory-products h4::after {
  content: "";
  display: block;
  height: 1px;
  background: #e6e8eb;
}

.b2biz-directory-products ul {
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.b2biz-directory-products li {
  min-width: 0;
}

.b2biz-directory-products a {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
  color: #374151;
  font-size: 14px;
  line-height: 1.5;
  text-decoration: none;
}

.b2biz-directory-products strong {
  flex: 0 0 auto;
  color: #ff4a00;
  font-weight: 400;
}

.b2biz-directory-products span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.b2biz-directory-products p {
  margin: 0;
  color: #8b95a1;
  font-size: 14px;
}

.b2biz-directory-card-compact .b2biz-directory-products li {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
}

.b2biz-directory-card-compact .b2biz-directory-products img {
  width: 54px;
  height: 54px;
  border: 1px solid #edf0f4;
  border-radius: 3px;
  object-fit: cover;
}

.b2biz-directory-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px auto;
  gap: 22px;
  align-items: center;
  min-height: 60px;
  margin-bottom: 20px;
  padding: 10px 26px;
}

.b2biz-directory-toolbar nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 30px;
}

.b2biz-directory-toolbar nav a {
  color: #374151;
  font-size: 16px;
  line-height: 40px;
  text-decoration: none;
}

.b2biz-directory-toolbar nav a.active,
.b2biz-directory-toolbar nav a:hover {
  color: #ff5a00;
}

.b2biz-directory-toolbar form {
  display: flex;
  align-items: center;
  min-width: 260px;
}

.b2biz-directory-toolbar input[type="search"] {
  width: 190px;
  height: 36px;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid #dfe3e8;
  border-right: 0;
  border-radius: 3px 0 0 3px;
  color: #374151;
  font-size: 14px;
}

.b2biz-directory-toolbar button {
  min-width: 64px;
  height: 36px;
  border: 1px solid #dfe3e8;
  border-radius: 0 3px 3px 0;
  background: #f8fafc;
  color: #111827;
  font-size: 14px;
  cursor: pointer;
}

.b2biz-directory-toolbar p {
  margin: 0;
  color: #5f6b7a;
  font-size: 15px;
  white-space: nowrap;
}

.b2biz-directory-toolbar span {
  color: #ff5a00;
}

.b2biz-directory-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
}

.b2biz-directory-pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 22px;
}

.b2biz-directory-pagination a,
.b2biz-directory-pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  height: 34px;
  padding: 0 10px;
  border: 1px solid #e3e7ed;
  border-radius: 3px;
  background: #fff;
  color: #5f6b7a;
  text-decoration: none;
}

.b2biz-directory-pagination a.active,
.b2biz-directory-pagination a:hover {
  border-color: #2f80ed;
  color: #2f80ed;
}

.b2biz-directory-empty {
  padding: 26px;
  background: #fff;
}

@media screen and (max-width: 1200px) {
  .b2biz-directory-layout {
    grid-template-columns: 260px minmax(0, 1fr);
  }

  .b2biz-directory-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .b2biz-directory-toolbar {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .b2biz-directory-toolbar p {
    white-space: normal;
  }
}

@media screen and (max-width: 960px) {
  .b2biz-directory-layout {
    grid-template-columns: 1fr;
  }

  .b2biz-directory-rank {
    min-height: 0;
  }

  .b2biz-directory-rank ol {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .b2biz-directory-featured-grid,
  .b2biz-directory-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media screen and (max-width: 640px) {
  .b2biz-directory-wrap {
    padding-top: 10px;
  }

  .b2biz-directory-rank ol,
  .b2biz-directory-featured-grid,
  .b2biz-directory-grid {
    grid-template-columns: 1fr;
  }

  .b2biz-directory-card-head,
  .b2biz-directory-card-compact .b2biz-directory-card-head {
    grid-template-columns: 66px minmax(0, 1fr);
    padding: 14px;
  }

  .b2biz-directory-card-logo,
  .b2biz-directory-card-compact .b2biz-directory-card-logo {
    width: 62px;
    height: 62px;
    border-width: 2px;
    border-radius: 50%;
  }

  .b2biz-directory-card-compact .b2biz-directory-card-logo img {
    border-radius: 50%;
  }

  .b2biz-directory-card-actions,
  .b2biz-directory-card-compact .b2biz-directory-card-actions {
    grid-column: 1 / -1;
    display: flex;
    margin-top: 0;
  }

  .b2biz-directory-toolbar form {
    width: 100%;
    min-width: 0;
  }

  .b2biz-directory-toolbar input[type="search"] {
    flex: 1 1 auto;
    width: auto;
  }
}
