

/* Portfolio Popup */
/* Переносим ЭТАЛОННЫЙ ДИЗАЙН (Variant B) на попап портфолио */
    .gm-video-popup-narrow.gbp-overlay-panel{
      background: transparent !important;
      padding: 0 !important;
      box-shadow: none !important;
    }

    .gm-video-popup-narrow .gm-gb-popup{
      background:#0b0b0b;
      border-radius:22px;
      overflow:hidden;
      display:flex;
      flex-direction:column;

      /* ВНЕШНЯЯ РАМКА 8px (эталон) */
      border:8px solid rgba(164,125,70,0.45);

      box-shadow:0 24px 70px rgba(0,0,0,0.65);
      max-height:84vh;
      margin-top:8vh;
      position:relative; /* чтобы крестик корректно якорился */
    }
    @media (max-height: 700px){
      .gm-video-popup-narrow .gm-gb-popup{ margin-top:3vh; max-height:92vh; }
    }

    /* В портфолио внутри попапа есть грид-слои; оставляем как есть, но даём скролл контенту */
    .gm-video-popup-narrow .popup-content{
      overflow:auto;
      -webkit-overflow-scrolling:touch;
    }

    /* Крестик — как в эталоне */
	    .gm-video-popup-narrow .gbp-overlay-panel__close{
	      background:rgba(255,255,255,0.18) !important;
	      color:#fff !important;
	      border-radius:999px !important;
	      width:44px !important;
	      height:44px !important;
	      padding:0 !important;
	      position:absolute !important;
	    }

	    .gm-video-popup-narrow .gbp-overlay-panel__close::before,
	    .gm-video-popup-narrow .gbp-overlay-panel__close::after{
	      content:"" !important;
	      position:absolute !important;
	      left:50% !important;
	      top:50% !important;
	      width:18px !important;
	      height:2px !important;
	      border-radius:2px !important;
	      background:#fff !important;
	      pointer-events:none !important;
	      z-index:2 !important;
	    }

	    .gm-video-popup-narrow .gbp-overlay-panel__close::before{
	      transform:translate(-50%, -50%) rotate(45deg) !important;
	    }

	    .gm-video-popup-narrow .gbp-overlay-panel__close::after{
	      transform:translate(-50%, -50%) rotate(-45deg) !important;
	    }

/* Video Popup */
/* === PANEL RESET === */
    .gm-video-popup-narrow.gbp-overlay-panel{
      background: transparent !important;
      padding: 0 !important;
      box-shadow: none !important;
    }

    /* === POPUP SHELL === */
    .gm-video-popup-narrow.gm-variant-b .gm-gb-popup{
      background:#0b0b0b;
      border-radius:22px;
      overflow:hidden;
      display:flex;
      flex-direction:column;

      /* внешняя рамка ~8px */
      border:8px solid rgba(164,125,70,0.45);

      box-shadow:0 24px 70px rgba(0,0,0,0.65);

      /* чтобы попап не “упирался” */
      max-height: 84vh;
      margin-top: 8vh;
    }
    @media (max-height: 700px){
      .gm-video-popup-narrow.gm-variant-b .gm-gb-popup{
        margin-top:3vh;
        max-height:92vh;
      }
    }

    /* === VIDEO: 9:16 + разумный максимум по высоте (чтобы не давило форму) === */
    .gm-video-popup-narrow.gm-variant-b .gm-video-wrap{
      position:relative;
      width:100%;
      aspect-ratio: 9 / 16;
      max-height: 46vh;             /* ключ: видео и окно “соотносятся” */
      background:#000;
      overflow:hidden;
    }
    @supports not (aspect-ratio: 9 / 16){
      .gm-video-popup-narrow.gm-variant-b .gm-video-wrap{
        height:auto;
        padding-top: 177.78%;
        max-height: none;
      }
      .gm-video-popup-narrow.gm-variant-b .gm-video-wrap > iframe{
        position:absolute;
        inset:0;
      }
    }

    /* === CONTENT === */
    .gm-video-popup-narrow.gm-variant-b .gm-popup-content{
      overflow:auto;
      -webkit-overflow-scrolling:touch;
      padding: 16px 20px 16px;
      display:flex;
      flex-direction:column;
      align-items:center;
      row-gap: 10px;
      text-align:center;
    }

    /* === TYPO (слегка собраннее) === */
    .gm-video-popup-narrow.gm-variant-b .gb-text-gmB_6e4edf5c{
      font-size: 20px !important;
      line-height: 1.2 !important;
      margin-bottom: 0 !important;
    }
    .gm-video-popup-narrow.gm-variant-b .gb-text-gmB_6afe48b0{
      font-size: 13px !important;
      line-height: 1.45 !important;
      margin-bottom: 4px !important;
    }

    /* === FORM: меньше высоты, меньше “громоздкости” === */
    .gm-video-popup-narrow.gm-variant-b .wpcf7 form input[type="text"],
    .gm-video-popup-narrow.gm-variant-b .wpcf7 form input[type="tel"],
    .gm-video-popup-narrow.gm-variant-b .wpcf7 form input[type="email"],
    .gm-video-popup-narrow.gm-variant-b .wpcf7 form textarea{
      box-sizing: border-box !important;

      height: 42px !important;          /* было избыточно */
      padding: 0 14px !important;

      font-size: 14px !important;
      line-height: 1.2 !important;

      border-radius: 18px !important;
    }

    /* кнопка */
    .gm-video-popup-narrow.gm-variant-b .wpcf7 form input[type="submit"],
    .gm-video-popup-narrow.gm-variant-b .wpcf7 form button,
    .gm-video-popup-narrow.gm-variant-b .wpcf7 form .wpcf7-submit{
      box-sizing: border-box !important;

      height: 48px !important;
      padding: 0 18px !important;

      font-size: 14px !important;
      line-height: 1 !important;

      border-radius: 22px !important;
    }

    /* сообщения CF7 */
    .gm-video-popup-narrow.gm-variant-b .wpcf7-response-output{
      font-size: 12px !important;
      line-height: 1.35 !important;
    }

    /* close: оставляем, но чуть легче по размеру */
    .gm-video-popup-narrow.gm-variant-b .gb-text-gmB_7ff0c05f{
      width: 42px !important;
      height: 42px !important;
    }

/* Contact Form 7 acceptance checkbox reset */
.wpcf7-form .wpcf7-acceptance input[type="checkbox"],
.wpcf7-form input[type="checkbox"],
.wpcf7-form input[type="radio"] {
  width: 16px !important;
  height: 16px !important;
  min-width: 16px !important;
  min-height: 16px !important;
  max-width: 16px !important;
  max-height: 16px !important;
  padding: 0 !important;
  margin: 0 8px 0 0 !important;
  display: inline-block !important;
  vertical-align: middle !important;
  appearance: checkbox !important;
  -webkit-appearance: checkbox !important;
}
