/* Shared site header + mobile burger menu (all pages except the two <x-dc> home pages). */

.pg-dd { position: relative; }
.pg-dd-caret { transition: transform .15s ease; flex: none; }
.pg-dd:hover .pg-dd-caret, .pg-dd:focus-within .pg-dd-caret { transform: rotate(180deg); }
.pg-dd-menu { position: absolute; top: 100%; left: 0; margin-top: 8px; background: #fff; border-radius: 14px; box-shadow: 0 10px 32px rgba(0,0,0,0.14); padding: 6px; min-width: 200px; opacity: 0; visibility: hidden; transform: translateY(6px); transition: opacity .15s ease, transform .15s ease, visibility .15s; z-index: 200; }
.pg-dd:hover .pg-dd-menu, .pg-dd:focus-within .pg-dd-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.pg-dd-menu a { display: block; padding: 9px 12px !important; border-radius: 9px; font-size: 14px !important; font-weight: 500; color: #374151; white-space: nowrap; text-decoration: none; }
.pg-dd-menu a:hover, .pg-dd-menu a.is-active { background: rgba(0,0,0,0.05); color: #14151a; }
.pg-dd-menu a.is-active { font-weight: 600; }
.pg-dd-menu a.pg-dd-all { border-top: 1px solid rgba(0,0,0,0.08); margin-top: 4px; padding-top: 11px !important; font-weight: 700; color: #14151a; }

.pg-hamburger { display: none; }
.pg-mm { display: none; }

@media (max-width: 767px) {
  .pg-add-btn-label { display: none !important; }
  .pg-add-btn { padding: 10px 12px !important; }
}

/* below 1024px the full nav no longer fits (esp. RU labels) */
@media (max-width: 1023px) {
  .pg-nav-links, .pg-nav-login { display: none !important; }
  .pg-hamburger { display: flex !important; }

  /* floats over the page, so opening it never shifts the content behind */
  .pg-nav-wrap { position: relative; }
  .pg-mm:not([hidden]) {
    display: block;
    position: absolute;
    top: 100%;
    right: 20px;
    width: calc(100% - 40px);
    pointer-events: all;
    margin-top: 8px;
    padding: 4px 20px 16px;
    background: rgba(255,255,255,0.97);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(255,255,255,0.9);
    border-radius: 18px;
    box-shadow: 0 8px 36px rgba(0,0,0,0.12);
    overflow-y: auto;
    max-width: 420px;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
  }
}

.pg-mm a, .pg-mm-toggle { display: block; padding: 13px 0; border-bottom: 1px solid rgba(0,0,0,0.06); font-size: 15px; font-weight: 500; color: #6b7280; text-decoration: none; }
.pg-mm a.is-active { color: #14151a; font-weight: 700; }
.pg-mm-toggle { width: 100%; display: flex; align-items: center; justify-content: space-between; background: none; border: none; border-bottom: 1px solid rgba(0,0,0,0.06); font-family: 'Manrope', sans-serif; font-weight: 600; color: #14151a; cursor: pointer; text-align: left; min-height: 0 !important; padding: 13px 0 !important; }
.pg-mm-toggle svg { color: #6b7280; transition: transform .2s ease; }
.pg-mm-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }
.pg-mm-sub[hidden] { display: none; }
.pg-mm-sub a { font-size: 14px; padding: 10px 0 10px 14px; }
.pg-mm-sub a.pg-dd-all { color: #14151a; font-weight: 700; }
.pg-mm-login { display: block; width: 100%; margin-top: 14px; padding: 12px !important; border-radius: 100px; border: 1.5px solid rgba(0,0,0,0.1); background: transparent; font-family: 'Manrope', sans-serif; font-size: 14px; font-weight: 600; color: #14151a; cursor: pointer; }

/* very narrow phones: logo + lang + add + burger must fit on one line */
@media (max-width: 400px) {
  .pg-nav-search { display: none !important; }
}
@media (max-width: 767px) {
  .pg-mm:not([hidden]) { right: 16px; width: calc(100% - 32px); }
}
@media (max-width: 340px) {
  header nav { padding-left: 14px !important; }
  header nav > a:first-child span { font-size: 14.5px !important; }
}
