/* ===== ROOT ===== */
#gg-customizer-wrapper {
  max-width: 460px;
  margin: 40px auto;
  padding: 24px;
  background: #ffffff;
  border-radius: 18px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.08);
  font-family: system-ui, -apple-system, BlinkMacSystemFont;
}


/* ===== PREVIEW CARD ===== */
#gg-preview-card {
  background: #ffffff;
  padding: 16px;
  border-radius: 14px;
  border: 1px solid #eee;
}

/* ===== IMAGE CONTAINER ===== */
#gg-container-preview {
  position: relative;
  width: 100%;
  height: 400px;        /* 🔽 reduced height */
  background: #ffffff;
  border-radius: 12px;
  overflow: hidden;
}

/* PRODUCT IMAGE */
#gg-product-image {
  width: 100%;
  height: 100%;
  object-fit: contain;

  pointer-events: none;

   object-fit: contain;
  display: block;
}

/* Color overlay clipped to image */
/* ===== IMAGE-ONLY COLOR OVERLAY (FINAL & SAFE) ===== */
.gg-image-wrap {
  position: relative;
}

#gg-product-image {
  position: relative;
  z-index: 1;
}

#gg-color-overlay {
  position: absolute;
  inset: 0;
  background-color: transparent;
  pointer-events: none;

  mix-blend-mode: multiply;
  opacity: 0.75;

  z-index: 2;
}

/* LOGO */
.gg-logo {
  position: absolute;
  z-index: 5;
  cursor: grab;
  user-select: none;
}

/* ===== CONTROLS ===== */
.gg-controls {
  margin-top: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.gg-field label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 6px;
}

.gg-controls input[type="color"] {
  height: 44px;
  border-radius: 10px;
  border: 1px solid #ddd;
}

.gg-controls input[type="range"] {
  accent-color: #d32f2f;
}

#gg-download-btn {
  margin-top: 10px;
  padding: 14px;
  background: linear-gradient(135deg, #d32f2f, #b71c1c);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-weight: 600;
  cursor: pointer;
}

/* ===== CONTROL LAYOUT ===== */

.gg-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.gg-field {
  background: #fafafa;
  padding: 12px;
  border-radius: 10px;
  border: 1px solid #eee;
}

.gg-field label {
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 6px;
  display: block;
}

/* Color input */
.gg-field input[type="color"] {
  width: 100%;
  height: 42px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
}

/* File input */
.gg-field input[type="file"] {
  font-size: 12px;
  width: 100%;
}

/* Range slider */
.gg-field input[type="range"] {
  width: 100%;
  accent-color: #d32f2f;
}

/* Download button */
#gg-download-btn {
  margin-top: 14px;
  width: 100%;
  padding: 14px;
  border-radius: 14px;
  font-size: 15px;
}

/* Image wrapper */
.gg-image-mask {
  position: relative;
  width: 100%;
  height: 100%;
}

.gg-image-wrap {
  position: relative;
  width: 100%;
  height: 100%;          /* 🔥 THIS FIXES IT */
  display: flex;
  align-items: center;
  justify-content: center;
}

#gg-canvas {
  width: 100%;
  height: 100%;
  display: block;
}
