:root {
  --gd-gap: 1.5rem;
}

.gd-columns {
  display: flex;
  flex-wrap: wrap;
  gap: var(--gd-gap);
}

.gd-col {
  flex-grow: 1;
  box-sizing: border-box;
  min-width: 0;
}

/* Column widths using calc to subtract half the gap from each side */
.gd-col-5   { flex: 0 0 calc(5% - calc(var(--gd-gap) / 2)); }
.gd-col-10  { flex: 0 0 calc(10% - calc(var(--gd-gap) / 2)); }
.gd-col-15  { flex: 0 0 calc(15% - calc(var(--gd-gap) / 2)); }
.gd-col-20  { flex: 0 0 calc(20% - calc(var(--gd-gap) / 2)); }
.gd-col-25  { flex: 0 0 calc(25% - calc(var(--gd-gap) / 2)); }
.gd-col-30  { flex: 0 0 calc(30% - calc(var(--gd-gap) / 2)); }
.gd-col-33  { flex: 0 0 calc(33.3333% - calc(var(--gd-gap) / 2)); }
.gd-col-35  { flex: 0 0 calc(35% - calc(var(--gd-gap) / 2)); }
.gd-col-40  { flex: 0 0 calc(40% - calc(var(--gd-gap) / 2)); }
.gd-col-45  { flex: 0 0 calc(45% - calc(var(--gd-gap) / 2)); }
.gd-col-50  { flex: 0 0 calc(50% - calc(var(--gd-gap) / 2)); }
.gd-col-55  { flex: 0 0 calc(55% - calc(var(--gd-gap) / 2)); }
.gd-col-60  { flex: 0 0 calc(60% - calc(var(--gd-gap) / 2)); }
.gd-col-65  { flex: 0 0 calc(65% - calc(var(--gd-gap) / 2)); }
.gd-col-67  { flex: 0 0 calc(66.6667% - calc(var(--gd-gap) / 2)); }
.gd-col-70  { flex: 0 0 calc(70% - calc(var(--gd-gap) / 2)); }
.gd-col-75  { flex: 0 0 calc(75% - calc(var(--gd-gap) / 2)); }
.gd-col-80  { flex: 0 0 calc(80% - calc(var(--gd-gap) / 2)); }
.gd-col-85  { flex: 0 0 calc(85% - calc(var(--gd-gap) / 2)); }
.gd-col-90  { flex: 0 0 calc(90% - calc(var(--gd-gap) / 2)); }
.gd-col-95  { flex: 0 0 calc(95% - calc(var(--gd-gap) / 2)); }
.gd-col-100 { flex: 0 0 100%; }

/* Mobile: stack all columns */
@media (max-width: 991px) {
  .gd-col-5,
  .gd-col-10,
  .gd-col-15,
  .gd-col-20,
  .gd-col-25,
  .gd-col-30,
  .gd-col-33,
  .gd-col-35,
  .gd-col-40,
  .gd-col-45,
  .gd-col-50,
  .gd-col-55,
  .gd-col-60,
  .gd-col-65,
  .gd-col-67,
  .gd-col-70,
  .gd-col-75,
  .gd-col-80,
  .gd-col-85,
  .gd-col-90,
  .gd-col-95 {
    flex: 0 0 100%;
  }
}

/*Styles*/
.gd-mcmd-designer {
  padding-top: 2rem;
}

.d-img-container { 
  border:1px solid #eee; 
  padding:12px; 
  background:#fafafa; 
  text-align:center; 
}

#image-holder {
  margin:auto;
  display:block;
  max-width:100%
}
.mcmd-thumbbar {
  width: 100%;
  margin-top: 10px;
  overflow: hidden;
  display: none;
}

.mcmd-swiper {
  width: 100%;
  overflow: hidden;
  height: 110px;
}

.mcmd-swiper .swiper-wrapper {
  width: 100%;
}

.mcmd-swiper .swiper-slide {
  width: 110px;
  height: 100%;
  flex-shrink: 0;
}

.mcmd-swiper .swiper-slide a,
.mcmd-swiper .swiper-slide img {
  display: block;
  width: 100%;
  height: 100%;
}

.mcmd-swiper .swiper-slide img {
  object-fit: cover;
}

/* Always show, icon only */
.mcmd-swiper .swiper-button-prev,
.mcmd-swiper .swiper-button-next {
  width: 28px;
  height: 28px;
  top: 50%;
  margin-top: -14px;

  background: transparent;
  box-shadow: none;
  border-radius: 0;

  color: #000;
  opacity: 1;

  transition: transform .15s ease, opacity .15s ease;
}

.mcmd-swiper .swiper-button-prev:hover,
.mcmd-swiper .swiper-button-next:hover {
  transform: scale(1.08);
}

/* Make the chevrons smaller/subtle */
.mcmd-swiper .swiper-button-prev:after,
.mcmd-swiper .swiper-button-next:after {
  font-size: 18px;
  font-weight: 700;
}

/* Nudge them slightly inward if you want */
.mcmd-swiper .swiper-button-prev { left: 6px; }
.mcmd-swiper .swiper-button-next { right: 6px; }

/* Disable state */
.mcmd-swiper .swiper-button-disabled {
  opacity: 0.25;
  pointer-events: none;
}

/* optional: keep arrows off on small screens */
@media (max-width: 991px) {
  .mcmd-swiper .swiper-button-prev,
  .mcmd-swiper .swiper-button-next {
    display: none;
  }
}


/*Desktop*/
@media (min-width: 992px) {
  .d-img-container {
    position: sticky;
    top: calc(240px + 12px); /*240px theme sticky header + 12px padding*/
    /*top: calc(50vh - 50px); /* 50vh minus half the container height */
    z-index: 10;
  }

  body.admin-bar .d-img-container {
    top: calc(240px + 12px + 32px); /*32px admin bar*/
  }

}
/*Mobile*/
@media (max-width: 991px) {
  .d-img-container {
    position: sticky;
    /*top: 96px; /* theme sticky header before scroll*/
    top: 72px; /*themed header scrolled*/
    z-index: 98;
    background: white;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  }
  #designer {
    padding-top: 2rem;
  }

  /*body.admin-bar .d-img-container {
    top: calc(72px + 46px); /*admin bar--- but it autohides so this isn't really necessary
  }*/

  /*body.admin-bar .d-img-container {
    top: 142px; /*46px admin bar 
    theme doesn't account for admin bar
  }*/

  .gd-mcmd-designer {
    padding-top: 11rem ;
  }
  .d-img-container {
    position: fixed;
    left: 0;
    right: 0;
  }
  #image-holder {
    max-width: 100%;
    max-height: 300px;
    height: auto;
  }
  .mcmd-swiper {
    height: 72px;
  }
  .mcmd-swiper .swiper-slide {
    width: 72px;
  }
}

/*PIN TO BOTTOM option
@media (max-width: 991px) {
  .d-img-container {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    padding: 10px;
    z-index: 100;
    box-shadow: 0 -2px 6px rgba(0,0,0,0.1);
  }

  #image-holder {
    max-width: 100%;
    height: auto;
  }
}
*/

/* Option buttons */
.property-button { 
  cursor:pointer; 
  border:1px solid #ddd; 
  padding:8px; margin:6px 0; 
  display:flex; align-items:center; 
  /*gap:0.75rem;*/
  background:#fff; 
  user-select:none; 
}

.property-button img { 
  /*max-width:64px;*/ 
  height:auto; 
  display:block; 
}
.property-button p { 
  margin: 0; 
  font-size: 14px; 
}

/* Selected state */
.property-button.selected { 
  border-color: #0073aa; 
  background: #f1fcff; 
}

/* Group spacing */
.options, .options .grp { 
  margin-bottom: 1rem; 
}

.grp-styles, .grp-colors {
  display: flex;
  flex-wrap: wrap;
}

.grp-styles .property-button {
  flex: 0 0 calc(50% - calc(0.75rem) / 2);
  flex-direction: column;
}

.grp-styles .property-button p, .grp-colors .property-button p {
  font-size: 12px;
  text-align: center;
  line-height: 1.2;
}

.grp-colors .property-button {
  flex: 0 0 calc(33.3333% - calc(0.75rem) / 2);
  flex-direction: column;
}

/* Size */
#step2 .options .grp, #step4 .options .grp-vases {
  display:flex; 
  gap:0.5rem; 
  flex-wrap:wrap; 
}

.grp-polish {
  width: 100%;
  margin-top:0.75rem;
}

.grp-polish label {
  font-size: 18px;
  font-weight: bold;
}

.options-polish { 
  display:flex; 
  gap:0.5rem; 
  flex-wrap:wrap; 
}

/*Vases*/
.grp-vases .property-button {
  gap:0.5rem;
}


/* Form fields */
input[type="text"], input[type="email"], textarea { width:100% !important; padding:10px 6px; border:1px solid #ccc; border-radius:4px; box-sizing:border-box; margin-bottom:8px; }

/* Submit */
.readon { display:inline-block; padding:8px 14px; background:#0073aa; color:#fff; border:none; border-radius:3px; cursor:pointer; }

/* Small utility */
label { 
  display:block; 
  margin-bottom:4px; 
  font-weight:500; 
}

label.inline {
  display: inline-block;
}

/* Disabled submit visual */
.readon.disabled {
  opacity: 0.5;
  cursor: default;
  pointer-events: none;
}

/*Thumbs*/

.gd-color-block {
  width: 64px;
  height: 64px;
  margin-bottom: 4px;
}

.property-button img.gd-vase-icon {
  height: 24px;
}

/*post content*/
.gd-mcmd-post-content {
  padding-top: 1.2rem;
}

/* gd-mcmd: overlay, spinner and thank-you styles */

/* overlay wrapper; hidden by inline display:none on the element, shown via [aria-hidden="false"] */
.gd-mcmd-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.35);
  z-index: 9999;
  display: none; /* kept here for dev fallback; template keeps inline display:none */
  align-items: center;
  justify-content: center;
}

/* visible state driven by aria-hidden attribute */
.gd-mcmd-overlay[aria-hidden="false"] {
  display: flex;
}

/* centered white panel inside overlay */
.gd-mcmd-overlay-panel {
  background: #fff;
  padding: 20px 24px;
  border-radius: 8px;
  box-shadow: 0 6px 18px rgba(0,0,0,0.25);
  display: flex;
  gap: 12px;
  align-items: center;
  max-width: 90%;
  width: auto;
}

/* spinner SVG wrapper */
.gd-mcmd-spinner {
  width: 28px;
  height: 28px;
  display: inline-block;
  animation: gd-mcmd-spin 1s linear infinite;
}

/* accessible status text block */
.gd-mcmd-status {
  font-size: 14px;
  color: #222;
}
.gd-mcmd-status .gd-mcmd-status-title {
  font-weight: 600;
  margin-bottom: 4px;
}
.gd-mcmd-status .gd-mcmd-status-sub {
  font-size: 13px;
  color: #666;
}

/* Thank-you message box (hidden by inline style on template) */
.gd-mcmd-thankyou {
  margin-bottom: 1rem;
  padding: 12px;
  border: 1px solid #e6f4ea;
  background: #f0fff5;
  color: #033;
  border-radius: 4px;
  display: none; /* template keeps inline display:none; this is a fallback */
}

/* When revealed via JS we remove inline style or set display via JS; add focus outline utility */
.gd-mcmd-thankyou:focus {
  outline: 3px solid rgba(0,115,170,0.18);
  outline-offset: 2px;
}

.gd-mcmd-thankyou p {
  margin:8px 0 0;
}

/* spinner animation */
@keyframes gd-mcmd-spin {
  100% { transform: rotate(360deg); }
}

/* small responsive tweak for overlay panel */
@media (max-width: 480px) {
  .gd-mcmd-overlay-panel {
    padding: 14px 12px;
    gap: 10px;
  }
  .gd-mcmd-status .gd-mcmd-status-title { font-size: 13px; }
  .gd-mcmd-status .gd-mcmd-status-sub { font-size: 12px; }
}