/* style.css */
html, body {
  overflow: visible !important;
}

#gci-insert-button {
  display: inline-block;
  background-color: #5a5a5a;
  color: #fff;
  padding: 10px 18px 10px 44px;
  border: none;
  margin-bottom: 6px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 2px 4px rgba(0,0,0,0.5);
  transition: background-color 0.2s ease;
  background-image: url('/images/giphy.256x256.png');
  background-repeat: no-repeat;
  background-position: 12px center;
  background-size: 20px 20px;
}
#gci-insert-button:hover,
#gci-insert-button:focus {
  background-color: #777;
}

.gci-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  overflow: visible !important;
  pointer-events: auto;
}

.gci-modal-content {
  position: relative;
  background: #222;
  color: #fff;
  border-radius: 8px;
  padding: 20px;
  width: 90%;
  max-width: 480px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.7);
  text-align: center;
  max-height: 80vh;
  overflow: visible !important;
  display: flex;
  flex-direction: column;
}

.gci-close-top {
  position: absolute;
  top: -5px;
  right: -5px;
  width: 30px;
  height: 30px;
  line-height: 28px;
  text-align: center;
  background: #c20202;
  color: #fff;
  font-size: 18px;
  font-weight: bold;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 2px 5px rgba(0,0,0,0.6);
  transition: background 0.2s ease;
  z-index: 10;
}

.gci-close-top:hover {
  background: #770000;
}

#gci-search-input {
  display: block;
  width: 100%;
  padding: 10px;
  margin-bottom: 12px;
  background: #333;
  color: #eee;
  border: 1px solid #555;
  border-radius: 4px;
  font-size: 15px;
}

#gci-search-button,
#gci-more-button {
  display: block;
  width: auto;
  padding: 8px 14px;
  margin: 8px auto 0;
  background: #444;
  color: #fff;
  border: none;
  border-radius: 4px;
  font-size: 14px;
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
  transition: background 0.2s ease;
}
#gci-search-button:hover,
#gci-more-button:hover {
  background: #555;
}

.gci-results {
  flex: 1;
  overflow-y: auto;
  margin-top: 14px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  padding-right: 6px;
}
.gci-results img {
  margin: 4px;
  width: 100px;
  height: 100px;
  object-fit: cover;
  border: 2px solid #666;
  border-radius: 6px;
  cursor: pointer;
}

#hidden-comment {
  display: none;
}

@media (max-width: 500px) {
  .gci-modal-content {
    padding: 16px;
    max-width: 95%;
  }
}