/* Game iframe owns its size now */
.gp-iframe{
  display: block;
  margin: 0 auto;
  background: #000;
  border: 0;
  border-radius: 8px;

  /* Fill available space, respect container width */
  width: 100% !important;
  max-width: 1200px;

  /* Tall play area with a cap */
  height: clamp(420px, 65vh, 900px) !important;
  max-height: 90vh;
}

/* Fullscreen fallback when native API is not available */
.gp-iframe.is-full{
  position: fixed;
  inset: 0;
  z-index: 9999;
  width: 100vw !important;
  height: 100vh !important;
  max-width: none;
  max-height: none;
  border-radius: 0;
}

/* Footer and actions */
.player-footer, .blur_dialog, .contact-popup {
  --shadow-2: 0px 6px 30px rgba(0,0,0,.05);
  --box-bg-color:#071860;
  --btn-control:#051a74;
  --btn-control-hover:#ff7f00;
  --color-primary:#fff;
  --btn-text-extent:#030712;
  --text-btn-control:#0a0a1a;
  --text-btn-control-hover:#fff;
  --border-btn:#ffffff3d;
  --color-content-popup:#9fadc5;
  --color-heading-popup:#ff7f00;
}
.player-footer{ border-radius:8px; position:relative; margin:12px 0 0; box-shadow:var(--shadow-2); width:100%; background:var(--e-global-color-primary); }
.player-footer__inner{ display:flex; align-items:center; justify-content:space-between; position:relative; padding:10px; z-index:0; }
.player-footer__item{ padding:0 10px; }
.player-footer__left{ display:flex; align-items:center; gap:8px; }
.player-footer__left img{ border-radius:4px; max-width:40px; object-fit:cover; }
.player-footer__left h1{ font-size:20px; font-weight:500; margin:0; color:var(--color-primary); }
.player-footer__actions{ display:flex; flex-wrap:wrap; align-items:center; justify-content:center; gap:8px; }
.g-footer__button { padding: 0.5rem !important; }
.g-footer__button{
  background:var(--btn-control) !important; color:var(--color-primary);
  border:0; width:40px; height:40px; transition:all .3s; border-radius:50%;
  box-shadow:var(--shadow-2); position:relative; display:flex; align-items:center; justify-content:center; cursor:pointer;
}
.g-footer__button .svg-icon{ width:18px; height:18px; transition:transform .2s cubic-bezier(.32,1.2,.54,1.17); }
.g-footer__button-title{ font-size:10px; bottom:4px; left:20%; position:absolute; transform:translateX(-50%); }
.g-footer__button-title_last{ opacity:0; }
.g-footer__button-title_first{ color:var(--color-primary); opacity:1; }
.g-footer__button-title_text{ border-radius:16px; padding:0 4px; transition:opacity .35s cubic-bezier(.32,1.2,.54,1.17); white-space:nowrap; background:var(--box-bg-color); font-weight:500; }

@media (hover:hover) and (pointer:fine){
  .g-footer__button:hover .g-footer__button-title_last{ background:var(--btn-text-extent); color:#fff; opacity:1; }
  .g-footer__button:hover .g-footer__button-title_first{ opacity:0; }
  .g-footer__button:hover{ transform:translateY(-3px); background:var(--btn-control-hover) !important; color:var(--text-btn-control-hover); }
}
.g-footer__button:hover .svg-icon{ transform:rotate(-5deg); }
.g-footer__button.voted, .g-footer__button.active{ transform:translateY(-3px); background:var(--btn-control-hover) !important; color:var(--text-btn-control-hover); }

/* Share modal */
.gp-share-modal[hidden]{ display:none; }
.gp-share-modal{
  position:fixed; inset:0; background:rgba(0,0,0,.55); z-index:10000;
  display:flex; align-items:center; justify-content:center; padding:20px;
}
.gp-share-card{ background:#071860; color:#fff; border-radius:12px; padding:18px; width:min(560px, 92vw); box-shadow:0 18px 60px rgba(0,0,0,.35); text-align:center; }
.gp-share-card h3{ margin:0 0 12px; color:#fbc401; font-size:1.1rem; }
.gp-share-input{ width:100%; padding:10px 12px; border-radius:8px; border:1px solid rgba(255,255,255,.2); background:#0b1b4a; color:#fff; margin:10px 0 16px; }
.gp-copy, .gp-close{ margin:0 6px; }

/* Social icons */
.gp-social { margin-left: 6px; display: inline-flex; align-items: center; justify-content: center; }
.gp-social svg { width: 18px; height: 18px; }
.gp-player {
        display: flex
;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

/* Mobile adjustments */
@media (max-width: 640px) {
  /* iframe width caps to 95 percent of the content column */
  .gp-iframe{
    max-width: 95% !important;
    height: clamp(360px, 60vh, 85vh) !important;
  }

  .player-footer__inner { display:flex; flex-direction:column; align-items:stretch; gap:10px; padding:10px; }
  .player-footer__left { order:0; width:100%; justify-content:center; gap:10px; text-align:center; }
  .player-footer__left img { max-width:44px; max-height:44px; }
  .player-footer__left h1 { font-size:18px; line-height:1.2; }
  .player-footer__actions {
    order:1; width:100%; justify-content:center; gap:10px;
    display:grid; grid-template-columns:repeat(auto-fit, minmax(44px, 1fr));
  }
  .g-footer__button { width:44px; height:44px; border-radius:50%; padding:0; }
  .g-footer__button .svg-icon { width:18px; height:18px; }
  .g-footer__button-title { display:none; }
  .gp-social { margin:0 auto; }
}
