/** Shopify CDN: Minification failed

Line 210:0 Unexpected "<"
Line 248:0 Unexpected "<"

**/
/* Base display for variant selects */
.variant-selects {
  display: block;
}

/* Flex container for different input types */
.product--no-media .product-form__input--pill,
.product--no-media .product-form__input--swatch,
.product--no-media .product-form__input--dropdown {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

/* Wrap pills and swatches */
.product--no-media .product-form__input.product-form__input--pill,
.product--no-media .product-form__input.product-form__input--swatch {
  flex-wrap: wrap;
  margin: 0 auto 1.2rem auto;
}

/* Dropdown specific styling */
.product--no-media .product-form__input--dropdown {
  flex-direction: column;
  max-width: 100%;
}

/* Label margin */
:is(.product-form__input--pill, .product-form__input--swatch) .form__label {
  margin-bottom: 0.2rem;
}

/* Hide radio inputs but keep accessible */
.product-form__input input[type='radio'] {
  clip: rect(0 0 0 0);
  overflow: hidden;
  position: absolute;
  height: 1px;
  width: 1px;
}

/* Hide unavailable label */
.product-form__input input[type='radio']:not(.disabled):not(.visually-disabled) + label > .label-unavailable {
  display: none;
}

/* Dropdown swatch sizing */
.product-form__input--dropdown {
  --swatch-input--size: 2rem;
  margin-bottom: 1.6rem;
}

.product-form__input--dropdown .dropdown-swatch + select {
  padding-left: calc(2.4rem + var(--swatch-input--size));
}

.product-form__input--dropdown .dropdown-swatch {
  position: absolute;
  left: 1.6rem;
  top: calc(50% - var(--swatch-input--size) / 2);
  width: var(--swatch-input--size);
  height: var(--swatch-input--size);
  z-index: 1;
}

/* --------------------------- */
/* Pill input styles */
/* --------------------------- */
.product-form__input--pill {
  /* nothing extra here, styles below target input + label */
}

.product-form__input--pill input[type='radio'] + label {
  border: var(--variant-pills-border-width) solid rgba(var(--color-foreground), var(--variant-pills-border-opacity));
  background-color: rgb(var(--color-background));
  color: rgb(var(--color-foreground));
  border-radius: var(--variant-pills-radius);
  display: inline-block;
  margin: 0.7rem 0.5rem 0.2rem 0;
  padding: 1rem 2rem;
  font-size: larger;
  letter-spacing: 0.1rem;
  line-height: 1;
  text-align: center;
  transition: border var(--duration-short) ease;
  cursor: pointer;
  position: relative;
    border-radius: 0 !important;
}

.product-form__input--pill input[type='radio'] + label:before {
  content: '';
  position: absolute;
  top: calc(var(--variant-pills-border-width) * -1);
  right: calc(var(--variant-pills-border-width) * -1);
  bottom: calc(var(--variant-pills-border-width) * -1);
  left: calc(var(--variant-pills-border-width) * -1);
  z-index: -1;
  border-radius: var(--variant-pills-radius);
  box-shadow: var(--variant-pills-shadow-horizontal-offset) var(--variant-pills-shadow-vertical-offset)
    var(--variant-pills-shadow-blur-radius) rgba(var(--color-shadow), var(--variant-pills-shadow-opacity));
}

.product-form__input--pill input[type='radio'] + label:hover {
  border-color: rgb(var(--color-foreground));
}

.product-form__input--pill input[type='radio']:checked + label {
  background-color: rgb(var(--color-foreground));
  color: rgb(var(--color-background));
}

@media screen and (forced-colors: active) {
  .product-form__input--pill input[type='radio']:checked + label {
    text-decoration: underline;
  }

  .product-form__input--pill input[type='radio']:focus-visible + label {
    outline: transparent solid 1px;
    outline-offset: 2px;
  }
}

.product-form__input--pill input[type='radio']:checked + label::selection {
  background-color: rgba(var(--color-background), 0.3);
}

.product-form__input--pill input[type='radio']:disabled + label,
.product-form__input--pill input[type='radio'].disabled + label {
  border-color: rgba(var(--color-foreground), 0.1);
  color: rgba(var(--color-foreground), 0.6);
  text-decoration: line-through;
}

.product-form__input--pill input[type='radio'].disabled:checked + label,
.product-form__input--pill input[type='radio']:disabled:checked + label {
  color: rgba(var(--color-background), 0.6);
}

.product-form__input--pill input[type='radio']:focus-visible + label {
  box-shadow: 0 0 0 0.3rem rgb(var(--color-background)), 0 0 0 0.5rem rgba(var(--color-foreground), 0.55);
}

.product-form__input--pill input[type='radio'].focused + label {
  box-shadow: 0 0 0 0.3rem rgb(var(--color-background)), 0 0 0 0.5rem rgba(var(--color-foreground), 0.55);
}

/* --------------------------- */
/* Swatch input styles */
/* --------------------------- */

.product-form__input--swatch {
  display: flex;
  flex-wrap: wrap;
  
  /* Move variable here for consistent usage */
  --swatch-input--size: 3.6rem;
}

.product-form__input--swatch .swatch-input__input {
  position: absolute;
  clip: rect(0 0 0 0);
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.product-form__input--swatch .swatch-input__label {
  width: var(--swatch-input--size);
  height: var(--swatch-input--size);
  border-radius: 0; /* square */
  display: inline-block;
  border: 1px solid rgba(var(--color-foreground), 0.3);
  cursor: pointer;
  position: relative;
  background-size: cover;
  background-position: center;
  margin: 0.7rem 1.2rem 0.2rem 0;
  transition: border-color 0.3s ease;
    border-radius: 0 !important;
}

/* Smaller swatch size on larger screens */
@media screen and (min-width: 750px) {
  .product-form__input--swatch {
    --swatch-input--size: 2.8rem;
  }
}

/* Highlight selected swatch */
.product-form__input--swatch .swatch-input__input:checked + .swatch-input__label {
  border-color: rgb(var(--color-foreground));
  outline: 2px solid rgb(var(--color-foreground));
}

/* Disabled state */
.product-form__input--swatch .swatch-input__input:disabled + .swatch-input__label,
.product-form__input--swatch .swatch-input__input.disabled + .swatch-input__label {
  border-color: rgba(var(--color-foreground), 0.1);
  opacity: 0.6;
  cursor: not-allowed;
}
<style>
  /* Container holding swatches */
  .product-form__input--swatch {
    display: flex;
    flex-wrap: wrap;
    --swatch-input--size: 40px; /* fixed size for clarity */
  }

  /* Hide native radio buttons */
  .swatch-input__input {
    position: absolute;
    clip: rect(0 0 0 0);
    width: 1px;
    height: 1px;
    overflow: hidden;
      border-radius: 0 !important;
  }

  /* Style labels as square swatches */
  .swatch-input__label {
    width: var(--swatch-input--size);
    height: var(--swatch-input--size);
    border-radius: 0;
    display: inline-block;
    border: 2px solid #999;
    cursor: pointer;
    margin: 0.5rem;
    background-size: cover;
    background-position: center;
    transition: border-color 0.3s ease;
  }

  /* Selected swatch highlight */
  .swatch-input__input:checked + .swatch-input__label {
    border-color: #007acc;
    outline: 2px solid #007acc;
  
  }
</style>

<div class="product-form__input product-form__input--swatch">
  <input type="radio" id="variant1" name="variant" class="swatch-input__input" />
  <label for="variant1" class="swatch-input__label" style="background-color: red;"></label>

  <input type="radio" id="variant2" name="variant" class="swatch-input__input" />
  <label for="variant2" class="swatch-input__label" style="background-color: blue;"></label>

  <input type="radio" id="variant3" name="variant" class="swatch-input__input" />
  <label for="variant3" class="swatch-input__label" style="background-color: green;"></label>
</div>
