/**
 * Silverless ACF Fields - Frontend Styles
 */

.acf-color-palette {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 10px 0;
}

.acf-color-palette__option {
  display: flex;
  flex-direction: column;
  align-items: center;
  cursor: pointer;
  padding: 8px;
  border-radius: 8px;
  transition: all 0.2s ease;
  border: 2px solid transparent;
  background: #fff;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.acf-color-palette__option:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.acf-color-palette__option.selected {
  border-color: #0073aa;
  box-shadow: 0 0 0 2px rgba(0, 115, 170, 0.2);
}

.acf-color-palette__swatch {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid #fff;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  position: relative;
  margin-bottom: 6px;
  transition: all 0.2s ease;
}

.acf-color-palette__option.selected .acf-color-palette__swatch::after {
  content: '✓';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: #fff;
  font-weight: bold;
  font-size: 16px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.acf-color-palette__label {
  font-size: 12px;
  font-weight: 500;
  color: #333;
  text-align: center;
  line-height: 1.2;
}

.acf-color-palette__custom {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 8px;
  border-radius: 8px;
  border: 2px dashed #ccc;
  background: #f9f9f9;
  cursor: pointer;
  transition: all 0.2s ease;
}

.acf-color-palette__custom:hover {
  border-color: #0073aa;
  background: #f0f8ff;
}

.acf-color-palette__custom-input {
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  margin-bottom: 6px;
}

.acf-color-palette__custom-label {
  font-size: 12px;
  font-weight: 500;
  color: #666;
  text-align: center;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .acf-color-palette {
    gap: 8px;
  }

  .acf-color-palette__swatch {
    width: 32px;
    height: 32px;
  }

  .acf-color-palette__custom-input {
    width: 32px;
    height: 32px;
  }
}
