/*
Theme Name: BilimGid Child
Theme URI: https://bilimgid.ru/
Description: Product child theme for BilimGid catalog. Parent theme: OneListing.
Author: BilimGid
Template: onelisting
Version: 1.0.0
Text Domain: bilimgid-child
*/

/* Consolidated public CSS moved out of inline wp_head/wp_footer output. */
.bmg-social.is-threads,
.bpg-social-link[href*="threads"],
.bpg-social-icon.is-threads {
  font-size: 0 !important;
  color: transparent !important;
  text-indent: -999px !important;
  overflow: hidden !important;
  background-color: #fff !important;
  background-image: url('https://bilimgid.ru/wp-content/uploads/2026/06/bilimgid-threads-icon.png') !important;
  background-repeat: no-repeat !important;
  background-position: center !important;
  background-size: 25px 25px !important;
}

.bmg-social.is-threads::before,
.bmg-social.is-threads::after,
.bpg-social-link[href*="threads"]::before,
.bpg-social-link[href*="threads"]::after,
.bpg-social-icon.is-threads::before,
.bpg-social-icon.is-threads::after,
.bpg-social-icon.is-threads span::before {
  content: none !important;
  display: none !important;
}

.bpg-social-icon.is-threads span {
  font-size: 0 !important;
  color: transparent !important;
}

.bpg-clean-content #primary.content-area {
  padding-top: 14px !important;
}

.bpg-catalog-page .bpg-page-hero,
.bpg-directory-page .bpg-page-hero,
.bpg-page .bpg-page-hero {
  padding-top: 34px !important;
  padding-bottom: 18px !important;
}

.bpg-catalog-page .bpg-center-card,
.bpg-results-panel .bpg-center-card {
  display: flex !important;
  flex-direction: column !important;
  height: 490px !important;
  min-height: 490px !important;
}

.bpg-catalog-page .bpg-center-photo,
.bpg-results-panel .bpg-center-photo {
  flex: 0 0 166px !important;
  height: 166px !important;
  min-height: 166px !important;
}

.bpg-catalog-page .bpg-center-body,
.bpg-results-panel .bpg-center-body {
  flex: 1 1 auto !important;
  min-height: 0 !important;
}

.bpg-catalog-page .bpg-center-title,
.bpg-results-panel .bpg-center-title,
.bpg-catalog-page .bpg-center-body strong,
.bpg-results-panel .bpg-center-body strong {
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
  min-height: 45px !important;
  max-height: 45px !important;
}

.bpg-catalog-page .bpg-card-facts,
.bpg-results-panel .bpg-card-facts {
  min-height: 28px !important;
}

.bpg-catalog-page .bpg-meta,
.bpg-results-panel .bpg-meta {
  min-height: 36px !important;
  max-height: 36px !important;
}

.bpg-catalog-page .bpg-card-actions,
.bpg-results-panel .bpg-card-actions {
  min-height: 42px !important;
  margin-top: auto !important;
}

.bpg-catalog-page .bpg-center-card.is-contact-missing .bpg-more,
.bpg-results-panel .bpg-center-card.is-contact-missing .bpg-more {
  margin-top: auto !important;
  background: #4867f5 !important;
  color: #fff !important;
  box-shadow: 0 12px 24px rgba(72, 103, 245, .18) !important;
}

.bpg-catalog-page .bpg-catalog-sort,
.bpg-results-panel .bpg-catalog-sort {
  display: flex !important;
  flex-wrap: nowrap !important;
  align-items: center !important;
  gap: 8px !important;
  overflow-x: auto !important;
  scrollbar-width: none !important;
  margin: 10px 0 18px !important;
  padding: 0 0 4px !important;
}

.bpg-catalog-page .bpg-catalog-sort::-webkit-scrollbar,
.bpg-results-panel .bpg-catalog-sort::-webkit-scrollbar {
  display: none !important;
}

.bpg-catalog-page .bpg-catalog-sort a,
.bpg-results-panel .bpg-catalog-sort a {
  flex: 0 0 auto !important;
  width: auto !important;
  min-width: 0 !important;
  min-height: 38px !important;
  padding: 0 15px !important;
  border-radius: 999px !important;
  white-space: nowrap !important;
}

.bmg-home .bmg-category-card {
  align-self: stretch !important;
}

.bmg-home .bmg-category-card strong {
  display: -webkit-box !important;
  -webkit-line-clamp: 3 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
}

@media (max-width: 980px) {
  .bpg-clean-content #primary.content-area {
    padding-top: 10px !important;
  }

  .bmg-home .bmg-hero-track {
    height: 286px !important;
  }

  .bmg-home .bmg-hero-copy h1 {
    font-size: 27px !important;
  }

  .bmg-home .bmg-hero-copy p {
    -webkit-line-clamp: 2 !important;
  }

  .bmg-home .bmg-search-panel {
    margin-top: 10px !important;
  }

  .bpg-catalog-page .bpg-results-panel {
    padding-top: 14px !important;
  }

  .bpg-catalog-page .bpg-results-head {
    margin-bottom: 8px !important;
  }

  .bpg-catalog-page .bpg-results-head h2 {
    font-size: 25px !important;
  }

  .bpg-catalog-page .bpg-catalog-sort,
  .bpg-results-panel .bpg-catalog-sort {
    margin: 10px -14px 14px !important;
    padding: 0 14px 4px !important;
  }

  .bpg-catalog-page .bpg-catalog-sort a,
  .bpg-results-panel .bpg-catalog-sort a {
    min-height: 40px !important;
    font-size: 13px !important;
  }

  .bpg-catalog-page .bpg-center-card,
  .bpg-results-panel .bpg-center-card {
    height: 486px !important;
    min-height: 486px !important;
  }

  .bpg-catalog-page .bpg-center-photo,
  .bpg-results-panel .bpg-center-photo {
    flex-basis: 166px !important;
    height: 166px !important;
    min-height: 166px !important;
  }

  .bpg-catalog-page .bpg-center-title,
  .bpg-results-panel .bpg-center-title,
  .bpg-catalog-page .bpg-center-body strong,
  .bpg-results-panel .bpg-center-body strong {
    min-height: 43px !important;
    max-height: 43px !important;
  }

  .bpg-catalog-page .bpg-card-actions a,
  .bpg-results-panel .bpg-card-actions a,
  .bpg-catalog-page .bpg-more,
  .bpg-results-panel .bpg-more {
    min-height: 44px !important;
  }

  .bpg-mobile-contact-bar {
    transform: translateY(120%) !important;
    transition: transform .22s ease !important;
    pointer-events: none !important;
  }

  .bpg-mobile-contact-bar.is-visible {
    transform: translateY(0) !important;
    pointer-events: auto !important;
  }

  .bmg-social.is-threads,
  .bpg-social-link[href*="threads"],
  .bpg-social-icon.is-threads {
    background-size: 27px 27px !important;
  }
}

@media (max-width: 420px) {
  .bmg-home .bmg-hero-track {
    height: 278px !important;
  }

  .bmg-home .bmg-category-card,
  .bmg-home .bmg-category-card:first-child {
    min-height: 80px !important;
  }
}

.bpg-manager-page {
  max-width: 1240px;
  margin: 0 auto;
  padding: 26px 18px 70px;
  color: #12172a;
}

.bpg-manager-hero,
.bpg-manager-login,
.bpg-manager-notice,
.bpg-manager-list,
.bpg-manager-editor {
  border: 1px solid #e2e8f5;
  background: #fff;
  box-shadow: 0 20px 48px rgba(20, 31, 72, .07);
}

.bpg-manager-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 24px;
  border-radius: 28px;
  background: linear-gradient(135deg, #fff, #f5f8ff);
}

.bpg-manager-hero span,
.bpg-manager-form-head span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  background: #ecfff7;
  color: #0f9b71;
  font-size: 12px;
  font-weight: 1000;
  text-transform: uppercase;
}

.bpg-manager-hero h1,
.bpg-manager-form-head h2 {
  margin: 12px 0 8px;
  color: #12172a;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.06;
  letter-spacing: 0;
}

.bpg-manager-hero p {
  max-width: 760px;
  margin: 0;
  color: #67728a;
  font-size: 16px;
  line-height: 1.52;
  font-weight: 750;
}

.bpg-manager-hero > a,
.bpg-manager-login a,
.bpg-manager-actions button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 20px;
  border: 0;
  border-radius: 16px;
  background: linear-gradient(135deg, #5d4dff, #286cff);
  color: #fff !important;
  text-decoration: none !important;
  font-weight: 1000;
  box-shadow: 0 14px 30px rgba(72, 103, 245, .22);
  cursor: pointer;
}

.bpg-manager-layout {
  display: grid;
  grid-template-columns: 340px minmax(0, 1fr);
  gap: 18px;
  margin-top: 18px;
}

.bpg-manager-list,
.bpg-manager-editor {
  border-radius: 26px;
}

.bpg-manager-list {
  align-self: start;
  padding: 16px;
  position: sticky;
  top: 20px;
}

.bpg-manager-filter {
  display: grid;
  gap: 10px;
  margin: 0 0 14px;
}

.bpg-manager-filter label,
.bpg-manager-form label {
  display: grid;
  gap: 7px;
  color: #667085;
  font-size: 12px;
  font-weight: 1000;
  text-transform: uppercase;
}

.bpg-manager-filter input,
.bpg-manager-filter select,
.bpg-manager-form input,
.bpg-manager-form select,
.bpg-manager-form textarea {
  width: 100%;
  min-height: 46px;
  border: 1px solid #dce5f4;
  border-radius: 15px;
  padding: 0 14px;
  background: #fbfcff;
  color: #12172a;
  font-size: 15px;
  font-weight: 850;
  outline: none;
}

.bpg-manager-form textarea {
  min-height: 112px;
  padding-top: 12px;
  resize: vertical;
  line-height: 1.45;
}

.bpg-manager-form select[multiple] {
  min-height: 210px;
  padding: 10px 12px;
}

.bpg-manager-filter button {
  min-height: 44px;
  border: 0;
  border-radius: 14px;
  background: #12172a;
  color: #fff;
  font-weight: 1000;
  cursor: pointer;
}

.bpg-manager-items {
  display: grid;
  gap: 8px;
  max-height: 62vh;
  overflow: auto;
  padding-right: 4px;
}

.bpg-manager-items a {
  display: grid;
  gap: 5px;
  padding: 13px;
  border: 1px solid #e5ebf6;
  border-radius: 17px;
  background: #fff;
  color: #12172a !important;
  text-decoration: none !important;
}

.bpg-manager-items a.is-active {
  border-color: #4867f5;
  background: #f3f6ff;
  box-shadow: inset 0 0 0 1px rgba(72, 103, 245, .22);
}

.bpg-manager-items strong {
  font-size: 14px;
  line-height: 1.25;
  font-weight: 1000;
}

.bpg-manager-items span,
.bpg-manager-empty {
  color: #717b92;
  font-size: 12px;
  line-height: 1.35;
  font-weight: 800;
}

.bpg-manager-editor {
  min-width: 0;
  padding: 22px;
}

.bpg-manager-form {
  display: grid;
  gap: 22px;
}

.bpg-manager-form-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding-bottom: 4px;
}

.bpg-manager-form-head h2 {
  font-size: clamp(24px, 3vw, 36px);
}

.bpg-manager-form-head a,
.bpg-manager-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 16px;
  border-radius: 14px;
  border: 1px solid #dfe7f5;
  background: #fff;
  color: #4867f5 !important;
  text-decoration: none !important;
  font-weight: 1000;
  white-space: nowrap;
}

.bpg-manager-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.bpg-manager-grid .is-wide {
  grid-column: 1 / -1;
}

.bpg-manager-form h3 {
  margin: 4px 0 -8px;
  color: #12172a;
  font-size: 20px;
  line-height: 1.2;
}

.bpg-manager-form em {
  color: #717b92;
  font-size: 12px;
  font-style: normal;
  font-weight: 850;
  text-transform: none;
}

.bpg-manager-checks {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.bpg-manager-checks label,
.bpg-manager-check {
  display: inline-flex !important;
  align-items: center;
  gap: 8px !important;
  min-height: 40px;
  padding: 0 12px;
  border: 1px solid #e3eaf6;
  border-radius: 999px;
  background: #f8faff;
  color: #263352 !important;
  font-size: 13px !important;
  font-weight: 950 !important;
  text-transform: none !important;
}

.bpg-manager-checks input,
.bpg-manager-check input {
  width: 18px;
  min-height: 18px;
  height: 18px;
  padding: 0;
  border-radius: 6px;
}

.bpg-manager-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  padding-top: 4px;
}

.bpg-manager-notice {
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 18px;
  background: #ecfff7;
  color: #0f8f6c;
  font-weight: 1000;
}

.bpg-manager-login {
  max-width: 720px;
  margin: 30px auto;
  padding: 32px;
  border-radius: 28px;
}

.bpg-manager-login h1 {
  margin: 0 0 10px;
  color: #12172a;
  font-size: clamp(28px, 5vw, 44px);
}

.bpg-manager-login p {
  margin: 0 0 18px;
  color: #667085;
  font-weight: 800;
}

@media (max-width: 980px) {
  .bpg-manager-page {
    padding: 16px 12px 48px;
  }

  .bpg-manager-hero,
  .bpg-manager-form-head {
    display: grid;
  }

  .bpg-manager-hero {
    padding: 20px;
    border-radius: 24px;
  }

  .bpg-manager-hero > a,
  .bpg-manager-actions button,
  .bpg-manager-actions a,
  .bpg-manager-form-head a {
    width: 100%;
  }

  .bpg-manager-layout,
  .bpg-manager-grid {
    grid-template-columns: 1fr;
  }

  .bpg-manager-list {
    position: static;
  }

  .bpg-manager-items {
    max-height: 320px;
  }

  .bpg-manager-editor {
    padding: 16px;
    border-radius: 22px;
  }

  .bpg-manager-filter input,
  .bpg-manager-filter select,
  .bpg-manager-form input,
  .bpg-manager-form select,
  .bpg-manager-form textarea {
    min-height: 50px;
    font-size: 16px;
  }
}

