    /* KOMCAT Market popup — стилі */
    #komcatModalOverlay,
    #komcatModalOverlay * {
      box-sizing: border-box;
    }

    /* Оверлей: центрує модалку по горизонталі та вертикалі */
    .komcat-modal-overlay {
      position: fixed;
      inset: 0;
      z-index: 99999;

      /* Центрування */
      display: flex;
      align-items: center;
      justify-content: center;

      /* Відступи + безпечні зони для iPhone */
      padding: max(16px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));

      /* Якщо контент вищий за екран — можна прокрутити */
      overflow-y: auto;
      -webkit-overflow-scrolling: touch;

      background: rgba(14, 17, 22, 0.72);
      backdrop-filter: blur(4px);
      -webkit-backdrop-filter: blur(4px);

      opacity: 0;
      visibility: hidden;
      pointer-events: none;
      transition: opacity 0.28s ease, visibility 0.28s ease;

      font-family: "Manrope", "Segoe UI", Arial, sans-serif;
    }

    .komcat-modal-overlay.show {
      opacity: 1;
      visibility: visible;
      pointer-events: auto;
    }

    /* Модальне вікно */
    .komcat-modal {
      /* margin: auto — критично для коректного центрування при overflow */
      margin: auto;

      width: min(92vw, 460px);
      max-height: calc(100vh - 32px);
      max-height: calc(100dvh - 32px);
      /* dynamic viewport height для мобільних */

      display: flex;
      flex-direction: column;

      background: #ffffff;
      color: #1f252e;
      border-radius: 18px;
      box-shadow: 0 20px 60px rgba(0, 0, 0, 0.28);
      overflow: hidden;

      /* Тільки scale — без translateY, щоб не зміщувати центр */
      transform: scale(0.96);
      transition: transform 0.34s cubic-bezier(.22, 1, .36, 1);

      border: 1px solid rgba(255, 122, 0, 0.12);
      text-align: left;
    }

    .komcat-modal-overlay.show .komcat-modal {
      transform: scale(1);
    }

    .komcat-modal-top {
      padding: 18px 18px 14px;
      background: linear-gradient(135deg, #fff7f0 0%, #ffffff 100%);
      border-bottom: 1px solid rgba(0, 0, 0, 0.06);
      position: relative;
      flex-shrink: 0;
    }

    .komcat-badge {
      display: inline-flex;
      align-items: center;
      gap: 8px;
      padding: 8px 12px;
      border-radius: 999px;
      background: rgba(255, 122, 0, 0.1);
      color: #d85f00;
      font: 800 12px/1 "Manrope", "Segoe UI", Arial, sans-serif;
      text-transform: uppercase;
      letter-spacing: .06em;
      margin-bottom: 12px;
    }

    .komcat-title {
      margin: 0;
      font-family: "Russo One", "Manrope", "Segoe UI", Arial, sans-serif;
      font-size: clamp(22px, 5vw, 32px);
      line-height: 1.1;
      color: #1f252e;
      padding-right: 46px;
      font-weight: 400;
    }

    .komcat-close {
      position: absolute;
      top: 12px;
      right: 12px;
      width: 40px;
      height: 40px;
      border: 0;
      border-radius: 12px;
      background: rgba(0, 0, 0, 0.05);
      color: #222;
      cursor: pointer;
      font-size: 22px;
      line-height: 1;
      transition: background 0.2s ease, transform 0.2s ease;
      padding: 0;
      font-family: Arial, sans-serif;
    }

    .komcat-close:hover {
      background: rgba(0, 0, 0, 0.09);
      transform: scale(1.05);
    }

    .komcat-modal-body {
      padding: 18px;
      overflow-y: auto;
      flex-grow: 1;
      -webkit-overflow-scrolling: touch;
    }

    .komcat-text-main {
      margin: 0 0 14px;
      font-size: 15px;
      line-height: 1.6;
      color: #5d6673;
    }

    .komcat-points {
      margin: 0 0 18px;
      padding: 0;
      list-style: none;
      display: grid;
      gap: 10px;
    }

    .komcat-points li {
      display: flex;
      align-items: flex-start;
      gap: 10px;
      font-size: 14px;
      line-height: 1.45;
      color: #1f252e;
    }

    .komcat-points li::before {
      content: "•";
      color: #ff7a00;
      font-weight: 800;
      font-size: 18px;
      line-height: 1;
    }

    .komcat-btn {
      display: inline-flex;
      justify-content: center;
      align-items: center;
      width: 100%;
      min-height: 48px;
      padding: 12px 16px;
      text-decoration: none;
      border-radius: 12px;
      font: 800 15px/1 "Manrope", "Segoe UI", Arial, sans-serif;
      border: none;
      cursor: pointer;
      background: linear-gradient(135deg, #ff932f, #ff7a00);
      color: #fff;
      box-shadow: 0 12px 24px rgba(255, 122, 0, 0.22);
      transition: transform 0.2s ease, box-shadow 0.2s ease;
    }

    .komcat-btn:hover {
      transform: translateY(-1px);
      box-shadow: 0 14px 28px rgba(255, 122, 0, 0.28);
    }

    .komcat-timer-wrap {
      padding: 0 18px 18px;
      flex-shrink: 0;
    }

    .komcat-timer-head {
      display: flex;
      justify-content: space-between;
      margin-bottom: 8px;
      font-size: 13px;
      color: #5d6673;
      font-weight: 700;
    }

    .komcat-timer-seconds {
      color: #d85f00;
      font-weight: 800;
    }

    .komcat-timer-bar {
      width: 100%;
      height: 8px;
      background: #ffe4cc;
      border-radius: 999px;
      overflow: hidden;
    }

    .komcat-timer-progress {
      width: 100%;
      height: 100%;
      background: linear-gradient(90deg, #ffb16a 0%, #ff7a00 100%);
      transform-origin: left center;
    }

    .komcat-timer-progress.animate {
      animation: komcatCountdown 15s linear forwards;
    }

    @keyframes komcatCountdown {
      from {
        transform: scaleX(1);
      }

      to {
        transform: scaleX(0);
      }
    }

    /* Мобільні: попап на всю ширину, з урахуванням висоти екрана */
    @media (max-width: 480px) {
      .komcat-modal-overlay {
        padding: 12px;
      }

      .komcat-modal {
        width: 100%;
        max-height: calc(100vh - 24px);
        max-height: calc(100dvh - 24px);
        border-radius: 16px;
      }

      .komcat-modal-top,
      .komcat-modal-body {
        padding: 16px;
      }

      .komcat-timer-wrap {
        padding: 0 16px 16px;
      }
    }

    /* Дуже низькі екрани (landscape на телефоні) */
    @media (max-height: 520px) {
      .komcat-modal {
        max-height: calc(100vh - 16px);
        max-height: calc(100dvh - 16px);
      }

      .komcat-title {
        font-size: 20px;
      }
    }